Take Control of Your Network: Install Uptime-Kuma on MikroTik

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
so in December a viewer actually came forward and asked me to make a video to cover uptime Kuma which I was actually very excited about however I couldn't get the container working on a marketing device so I kind of just abandoned the project however I did receive a notification from another viewer that they posted on the marketing forums and Microtech actually posted a slight workaround to get the container working I've tested it out and it works perfectly so in this video we will be looking at how to install uptime Kuma as a container on a marketec device and it's going to be awesome so hope you enjoy foreign well in essence it is a monitoring robot it will let you know if anything happens on your network your servers or even your website it is completely open source and it was developed by Lewis Lam as a bit of a project for himself because he couldn't find what he was looking for so he just made it himself and it's crazy how fancy and modern uptime Kuma is and all of the features that you get with it you can even do stuff like create status pages that people can view to see specifically what's happening with the network and it's so cool and it also allows you a way of automatically pushing notifications to stuff like Discord slack text messaging Telegraph email there's various different ways that you can actually get notified if an issue occurs on the network which I love one more thing to take note of is this isn't limited to just marketing you could install uptime Kuma on any type of server or Linux based host if you have some rest pretty pie lying around you could install uptime Kuma on that using something like Docker and Docker compose and it would work just as well personally I just love the idea of having this Mega router that has all of these networking functions that it can do all of these cool things so let's actually go about installing the uptime Kumar container on a micro tick so firstly let's just make sure that our device is capable of running containers so to do this we can just navigate into our terminal and we can do a system device mode print it will tell us container yes if it says no or nothing there what you could do to enable this is just run a system device mode update container equals yes when you hit enter it will ask you that you need to hard reset the device which in essence means pull the power completely when you power it back on it will boot up in a way of using containers very important if you don't do this containers won't work and again this is only going to be for your x86s your chrs or your arm or arm64 Arc texture anything older unfortunately you're not going to be doing containers next step is actually downloading the package from Microtech now I've already got the package installed if I go to my system and packages I have a container package now you can get the container package by going to the marketing website going to the software and then from the software you can navigate to your specific architecture so in my case it is an x86 if you download the extra packages you will find the container package in there from there it's just a case of copying the container image or the file into your Microtech in its file systems you just copy drag drop it in here reboot the micro tick when it boots back up it will have container functionality namely this little tab at the bottom left that says container if you click on this it will open up the container magic so from here you can actually install or pull containers you can configure stuff namely like Mount and here I see I have a mount that I'm just going to delete because we're going to do that ourselves just now but in essence Mount allow you a way of specifying stuff like certain directories to write data that the app wants to use that the container wants to use it might be some database type traffic where it wants to store information so this is very useful for us especially with uptime Kuma and then you have stuff like environment variables which allows you a way of changing some of the details in the container maybe you want to update the password or you want to change the port of the device not all containers have environment variables that you can change but in essence sometimes you will see it in the documentation that they say hey use this variable then you can change these details on the container which is really nice now first thing that we need now after the containers is a network to actually run stuff on now this is what I'm going to call my container Network and if I look at my bridges you will see I actually have a bridge called Dockers and within the Dockers there's these ports and these ports are all virtual ethernet interfaces that the containers use as their nics it's how they obtain IP addresses it's how they connect to the micro tick to each other and even to the internet very important to take note of that so if I go to my interfaces you can see there is a ve tab or you can just click on this drop down and you can click on VE this is how we can add a new virtual ethernet interface for our containers now I need a new interface from my uptime Kuma container so I will add it so long what I tend to do is I just leave the ve name whatever it is so ve 6 in this case I'll give it a little Dash and I'll give it a description of what it is like Kuma so now I know this is for the kuma container my address will be the IP address that the container will use so I will just statically assign this as 10.0.0.10 24 and my Gateway is going to be 10.0.0.1 which is the docker Bridge interface IP address I'll show that to you now as well so if I hit apply I will have this new interface which has been created and we can see it is just in our state because I haven't set it into that Bridget so if I go to my bridges in my ports I can just hit the plus and I can add my Kuma to the Dockers bridge if I hit apply the kuma interface is now added to the Dockers bridge and again what I mentioned was if I go into my IP addresses you will see that the ipf1000.124 is assigned to my Dockers so this now allows my containers network access which is really useful so now let's actually install the container since we have our Network portion set up so to do this I'll just navigate back to the containers boxes or container field and another thing just make sure in your config these are also important details to set the registry URL in essence is where it will be downloading containers from if you use the remote image method and in this case it is https colon forward slash forward slash registry-1 dot Docker dot IO so this allows you to pull images from the docker Hub second thing is the disk one forward slash pool this is just where it's going to be pulling images temporarily whilst extracting it so it can be installed on your mic so just make sure these diesels are there so you can actually install your containers so let's actually install Kuma now so we're nearly ready to bring our container online but first thing we want to set is a mount for our container so I'm going to go into the mounts tab I'll click on the plus and then from here we can give it a name so I'll just call this Kuma my source will be disk one forward slash Kuma underscore data so think of this as locally where I'm going to be storing this information on my marketing and destination is what I'm going to be pulling from the container in essence and this is going to be app forward slash data I will hit apply and now we have our Mount configured so with the mount we can now add our container so I'll go back to the container tab click on the plus we can specify a remote image what do we specify how do we get this image well if I go into my browser we can actually go on to the hub.docker.com and then you can search for uptime Kuma so uptime Dash Kuma and you should find it with the first hit the Lewis lamb one if I go in here we can now find the tag that we can use which is Lewis lamp forward slash uptime Dash Kuma so I'll just copy be this I'll go back onto my Mica tick and I'll paste it in here our interface I'm going to set this as my Kuma interface that I configured earlier then I need to specify my root directory now this can be an external drive for example if you don't have enough space on your actual marketing because you've added an external drive but I'm just going to make this disc one forward slash Kuma I've actually got quite a beefy CHR or x86 on my virtual Network so I'm not too worried about space and now our mounts we just need to set that Kuma Mount that we created I will enable logging and I will click on apply now once I click on apply it will now actually be pulling the container off of hub.doctor.com and it will extract it so now we're actually just waiting for this image to be installed and we will see it's finished when the status is done so I'm just going to pause the video here alright now we are in our final steps to actually get this working we can see the status is stopped we can see our architecture is AMD 64 and the osis Linux so I'm actually quite happy with this so far so my issue before was whenever we try to start this container if I click on start you'll see it goes running and then it immediately goes stop and I want to go into the logs quickly because we did enable logging and if we look here it will give us an app.data forward slash DOT type operation not permitted so it's it's freaking out about something and this is where micro TX Anton actually came in with a workaround which I really appreciate thank you marketing and Anton you guys are awesome when you suggested this and I couldn't believe this worked when I tested it out myself but if you actually log on to your micro device FTP system this DOT type file you can actually just delete that and the container works fine afterwards so let's quickly do that so I'm just gonna go on to my actual Linux machine now I'm going to go into my terminal and what I'm going to do is I'm just going to SFTP as admin onto my microtix IP which I actually think is 192.168 149132 and I'll just log in with my password now I'm in SFTP so I'm just going to change directory to disk 1 which is that directory we added and then there is a Kuma underscore data which is where it's complaining about that file now if I look here we should see there is a DOT type file and it is actually hidden so this is where you can't just normally find it there is actually one line command you can use to just delete this but I want to show you guys the process and the steps so from here we can just remove this DOT type file once that's done I can quit out of SFTP and if I minimize that and I close my log window and I try and start the container again let's see what happens running and it's not going into a stop state so this means we are actually off to a great start so let's actually see if it's working by navigating onto Kuma on our browser so all I'm going to do is go on to my browser and then from here I will just type in the IP address that I gave the container which was 10.0.0.10 on colon Port 3001. if you look at the documentation you will see it also tells you to connect on 3001. if I go back here it is going to be on HTTP you connect so once I hit enter it's going to ask me what's your language I'm going to leave it as English you can set a username so I'll make it the network word and then you can set your own password once you click create you will be inside uptime Kuma now the fun starts now we can actually start adding our monitoring and make this awesome solution work on our marketing so a few things to take note of is we can see nothing is configured at the moment so we won't actually see anything no monitors please add one so let's quickly add a monitor how to do this is we can just click on the Plus on add new monitor and there are various different ways that you can set your monitors your sensors so to speak so if you click on this drop down box here are your general types that you can use you've got your HTTP where it will just see if a site is up if it gets a certain response back from the site you've got TCP ports that you can use you can use ping you can use HTTP with a keyword which is so cool and crazy because it will in essence go to the site and see if the word exists on the site you can check stuff like DNS it's really really really awesome but let's just start off with a very basic ping because people like to just do ping you can give it a friendly name and this is just a description that you can see on the dashboard so let's call this maybe Google and our host name is now going to be the Google DNS server 8888 this is a pretty basic sensor that I think a lot of people tend to use we can set a heartbeat interval retry times before it says that it's actually down before it sends a notification the because maybe you know that it is uh you've got some type of wireless link and maybe sometimes a packet does drop here and there so maybe you just want to set that for three retries before it marks it as down and then we can also do stuff like an upside down mode which is just in Reverse so if it's up it will mark it as downward it's it's pretty crazy but don't worry too much about the upside down mode uh and then we can add some tags now tags are obviously nice because it just gives you that color coding of where what device is so I might just call this tag internet and then any internet facing Services I will just Mark with this tag I will give it the blue color and I will save this once this is saved automatically we can see the sensor for Google comes up it is pinging 888 and we can see what it's doing so it will tell you if it's up what the time is there's a nice little response graph here you can even go back quite a while you can clear your data but I'm not going to clear any data and it's nice because it will give you messages if something happens if something breaks if something becomes unreachable which I really really really appreciate now now that we have one monitor how about we add another monitor so let's maybe add something like the HTTP one and we can give it a friendly name and this I'm going to call my Eve NG because it's my even G server and now we can specify the URL so in my case the URL is https colon forward slash forward slash 192.168149.200 and I can leave the heartbeat in this case whatever it is currently and here we can see we do have a few extra options with Advanced you can check for certificate expiry notifications it will tell you if the SSL cert might be expiring and you can also do stuff like ignore TLS slash SSL so that if there's an error with the cert that it won't be marked as down which I'm actually going to leave like this for now because it's going to mark it as down even though I know even G is up so let me hit save oh wait let's just go over the accepted status quotes quickly as well so these are just HTTP codes you've got 200 304 and 500 100 Etc so anything in the 200 ranges typically when things are fine your 400 is typically when there's an issue on your side with your machine and then 500 would be a server-side issue you can have a look at the HTTP codes because it is a general it thing it's not just for Kuma or monitoring or anything it's more related to how sites work but we will leave it as 200 because 200 is typically what a site will send back to you when you connect and everything is successful so we're happy with that let's just give it the same tag as intranet so I can just select it from here actually no let's give it a new tag so I'm going to cancel that add a new tab how do I there we go remove as you see that's on here I am to adding the tags so let's add a tag and call this lab and this I'm going to Mark as red so this I know is going to be part of my lab infrastructure so I can save this and we can see it there now I can see that even G self-signed certificate that is down so if I look at my logs here we can actually see that the sensor is technically up but it's a self-signed certificate so if I edit this and I just ignore the TLs SSL Error and I save it again you'll see that it comes up and if I go back to my dashboard how nice is that we can see there we get that 200-okay it is up and we know that it was down but due to itself certificate so it is actually up everything is working and now we can see two of our hosts are up and running let's maybe add another monitor for our micro tick now so I'll make this one ping again let's just call this my micro tainer which is the Microtech this device connects on I can give it the host name IP so I can either give it its Wan IP of the microtec or I can make it the 10 but that would be weird making it the 10 0 0.1 since it's the container so if this marketing dies everything dies but I think the point that I want to make is if we can monitor different parts of our Network it also just gives us a little bit of extra foresight so let's say it was a separate micro ticket it was something else in my lab or an eve device or router we could set it up like this as well so I'll just also make the slab facing and I'll just save this and there we go so now we have have a bunch of different sensors when we're monitoring Google we're monitoring an evng site we're monitoring mic retainer so let's just add one more sensor actually using a host name and let's maybe use that keyword as well so I'll add a new monitor I'll use the HTTP as keyword we can give it a friendly name so maybe I will make this the Firefox 200. if I go to my URL I actually had this developer.mozilla.org URL earlier it's just a taste just to basically explain what the 200 okay is as well and here we can look for specific details so maybe I want to look for not just 200 okay let's maybe search for something else how about browser compatibility that's a weird thing to say but let's just use that and the search is case sensitive again so what this does is it actually loads up the website it will be like a person browsing it it will look for a specific word that we specified just to verify the site is actually working and that's it click on Save we can see it is added successfully and OK keyword is found so now we know it as actually able to see the keyword as well which is nice to an extent as well because I know back in the day when sites used to get hacked hackers might have changed the home page they changed the details things just changed and the site's not yours anymore one day you've got your nice website the next day it's a crypto Bros campsite and it doesn't have that keyword anymore so this is also a great way to just maybe get a notification if something fishy is happening on any given website now what happens if I change that keyword what will happen if I change this to something random so let's just type something random if I save this oh and let's also just give it an internet facing tag so when I save this we should see hey this goes down so that is awesome so if I look at my dashboard I've got all of these messages I can see what has happened on the network we're using eyepiece we're using DNS we're using websites everything's working the way we want I love it this is so cool modern and fleshed out but now we only know how to monitor the sensors how about we want to get notified how do we get notified so if I go into just a specific effect sensor and I press the edit button we will see there is a setup notification now we can set up various notifications what I'm going to use I'm just going to go on to my actual profile on the top right going to the settings and if we go into the notifications bar we can now set here some details like how we want to get notified now I'm going to use a Discord bot almost to get notified so if I have Discord installed on my phone and I have this Discord server on the phone I can actually get these notifications to see what's happening so let's set up notification and again here you can see there's various different ways to get notified you've got so many things slack Microsoft teams telegram but I'm going to use Discord so Discord I can give it a friendly name so my Discord alert seems fine I'll leave it as that now we need to set the Discord web hook URL so think of this as a fancy way of just to integrate your application with Discord or whatever means that you want to use it is also going to be very important I'm going to open up the score and I want to stress something with you guys that I have created a custom server which is void there's nothing going on in here because webhooks can also be a double-edged sword almost because if I right click on this notifications Channel and I edit the channel and I go to Integrations we can see there is a web hook currently now this web Hook is going to allow this Captain Hook box so to speak um to post in the server so if I go in here I can copy the web hook URL and by that it's not too bad but if somebody gets a hold of your web hook URL they can use it to maliciously post stuff so please make sure you keep your web hook secure don't just share stuff like I'm pasting here in here you can see I've got this whole code here the reason I'm not worried is because that is a burn server I'm going to just kill the server after this demonstration so that's fine for me but make sure that you stay secure whenever you're configuring these details now we can give the bot a name even I'll just leave it as uptime Kuma I can give it a custom message so hello add everyone or you can make it at specific people like ad Network Engineers or network admins or server Engineers or admins or whatever so that they can see the special message but I'll just leave this as hello and what's noises we can now set additional features where we can say default enabled so any new sensors that we add will by default have this notification attached to it and we can also even apply it on all existing monitors so let's do that as well I'm going to save this and now that that's been saved we can actually test it out so let's go back into the notification I can just click on edit here and if I click on test cool I heard that Discord message so if I look at the Discord server I should see my Discord alert testing awesome so we know that the bot is able to actually send messages now to Discord to let us know what's happening so let me close this and let's actually taste this in the event of something going down so let's maybe go into my Eve server let's edit something let's break something so let's just maybe make a bit of a typo or actually let's just change the code let's say it's actually looking for a 500 code now which means that stuff's broken but it's not going to receive the 500 because the server is actually up and working fine but there we can see something went down so if I look at my dashboard something went down but if I go on to Discord whoa I get a cool crazy notification to say hello Your Service even G went down what's the service name what's the URL when it went down what the error is how freaking cool is that and the nice thing is if the service comes back up it will also let us know that so if I go back into even G I edit this and let's just change that code back to 200 and let's just save this whoa I love it I love it this is so cool so now it's telling us that our service has restored and this is so fast it's in real time there's no email I'm waiting for there's no scripts that needs to run it's just like instantaneously that I'm getting these notifications that stuff is working or it's up it's down whatever is happening on the network or the servers or the websites it's just letting me know how cool is that guys so one more thing that I want to cover with uptime Kuma well there's a couple of things we can quickly go through if I go to the settings as well there's other stuff that you can add here like reverse proxies another cool feature with the security you can even enable 2fa so multiform Factor authentication it's all there and again this is a single person that made all this stuff for us we look at the about backups it's crazy it's really really crazy and I want to now show you guys just the status page so if we go to our status page this allows us a means of Administrators to also give a nice little status page that people can go to if they want to see if something's happening even for us we can load this up on our phone and then see what's going on so if I add a new status page I can just call this my status and I'll just call this tmb Kuma this slug is basically just a sub directory so you can have multiple different statuses that you can share with different people so that they can only see certain parts if you only want to have them have access to certain parts so let's go on to next and now from here first thing I want to do is just switch this to dark mode it looks a bit easier on the eyes we can now add our groups or our monitors so let's add our monitors I will add all of them quickly so Google Eve microtainer Firefox great and here it picks up partially degraded service because it see something is down and that is so sweet that is so awesome I'm just going to save this and what I want to do is actually just copy the status page and go on to this from my actual Windows computer so just give me a second so from my Windows computer if I open this status page and again this could be just a normal person they can go here and they can see hey there is a partially degraded service the Firefox stuff is down how neat is that and you can even add custom messages so if I edit my status page I can create an incident I can give it different colors so primary green should be good info is blue we have warning orange red danger you know different types of things that we compose to people so that they can see it so I can do an info one maybe and I can say Eve NG server my internet server will reboot it at whatever time and if I post this and I save it and let's go back to my Windows computer let's just refresh the page we can see a notification because the admin told us there's going to be something happening on an insane brief if you edit it you can change this to something else we can make it a danger we can even say here internet down it was bgp it's post then and save it and again if we refresh the page we get a nice little update on what's happening so I really like this status page feature as well and there's so much more all of these little things but I I really find it so fascinating that we have all these tools at our disposal for free using uptime Kuma and even containers on marketing I love it and I can't not not use it I'm going to keep using this in my own network and my own projects so tell me are you going to use uptime Kuma in your networks how do you feel about this did you enjoy the video and yeah this is where we're going to be signing off I'd like to thank everybody for watching as well as my YouTube and patreon members and I'll catch you guys in the next video see ya [Music] foreign
Info
Channel: The Network Berg
Views: 13,716
Rating: undefined out of 5
Keywords: Container, Docker, Free Monitoring, Free Network Monitoring Software, Free Network Monitoring Tool, MikroTik, Monitoring, Monitoring Sensor, Network, Network Monitoring, RouterOS, RouterOSv7, Sensors, The Network Berg, TheNetworkBerg, alternative to uptime robot, docker, latvia, mikrotik basics, mikrotik router, mikrotik training, routerboard, routeros, routeros v7, uptime, uptime kuma
Id: vzT00PlP1G8
Channel Id: undefined
Length: 25min 37sec (1537 seconds)
Published: Tue Jan 10 2023
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.