Recently I was speaking to a friend about Mikrotik routers and he mentioned that you could download a copy of their RouterOS software to experiment with. I hatched a plan to model a small network with such a router at its core and see what can be done with it in terms of monitoring using SNMP-based tools.
First, I would need to set up a fresh virtualisation platform to play with. I plopped a spare hard drive in to my gaming rig and installed openSUSE LEAP 42.2 on to it. That’s the easy bit of course, but I thought it would be interesting to look in more detail at setting up virtualisation using KVM as the hypervisor and some of the issues I encountered.
The ‘Yast ‘ application has a very useful option for installing a hypervisor. Here’s what it looks like:
Clicking on this item then gave me an option to choose which hypervisor:
Part of the installation process includes offering to set up a network ‘bridge’. My PC has one physical network device, ‘eth0’ and it has a static IP address (192.168.1.101) on my house network. The bridge will appear as ‘br0’ and will allow my virtual machines to access the house network using IP addresses in the same range as my other computers (i.e. 192.168.1.x)
Let’s check that the network has been created by using the ‘ip’ command line tool to see what the state of my network is…
Ah, but there’s a problem… when I booted up the computer a little while later, I had no network connection. For some reason the routing table had become confused. The IP address was linked to the bridge ‘br0’ but the default gateway was linked to the original ethernet adapter ‘eth0’. This is easy to fix in Yast under ‘System’ -> ‘Network Settings’. Find the entry on routing and change the device from ‘eth0’ to ‘br0’. Fixed!
In another post I will look at setting up ‘Virtual Machine manager’ and install a copy of RouterOS to play with.