Skip to main content

Posts

Showing posts from August, 2010

Centralised backup of Mikrotik RouterOS configuration

A common way to backup routeros is to use a script on each device that saves the config and emails it to a dedicated mailbox. Although this works as advertised, I prefer this centralised approach that pulls the configuration from each device. The method I chose was to backup each device using FTP to a central server. Yes there is some configuration required on each device, but once set up, it's definitely a set and forget solution. This requires routerOS on x86 platform - the free 'demo' license will do :) No fancy-pants features, just some basic IP addressing. This works perfectly as a virtual machine. In my case, ESXi. Create a VM with enough storage for all your backups. Basically, you create a CSV file of all your devices and IP addresses. The script below will ftp to each entry and GET the backup file appropriately named 'HOSTNAME.backup'. It will just overwrite the last one, but it would be easy to change this behaviour and have it append.

System History and the undo command

The history of system configuration changes is held until the next router shutdown. The invoked commands can be 'undone' using the /undo command. By invoking the command several times, the configuration changes can be 'undone' in reverse order they have been invoked. Use the /system history print command to see the list of performed actions: [MikroTik] system history> print Flags: U - undoable, R - redoable, F - floating-undo    ACTION                                   BY            POLICY           U nat rule changed                         admin         write            U nat rule changed                         admin         write   [MikroTik] system history> The list is printed with the newest actions at the top. Thus, in this example, the /undo command would 'undo' the changed nat rule from the top: [MikroTik] system history> /undo [MikroTik] system history> print  Flags: U - undoable, R - redoable, F - floating-undo    AC

USB Extender over CAT5E or CAT6 connection

Extend USB up to 45 meters over cat5e/6. I was wanting to get my big ugly printer off the desk next to the computer and put it in another room. I don't have the luxury of a wireless printer. This would be perfect. http://www.monoprice.com/products/product.asp?c_id=103&cp_id=10303&cs_id=1030304&p_id=6042&seq=1&format=2

Vlans over wireless link

Take this scenario. We want the laptops on vlan 100 and the PCs on vlan 200. We don't want communication between vlans. Here is how it would go, assuming the wds link is configured and working. 1. create the vlan interfaces /interface vlan add name=vl-laptops-wds1 vlan-id=100 interface=wds1 disabled=no add name=vl-pc-wds1 vlan-id=200 interface=wds1 disabled=no Note that the name of the vlan interfaces can be what you like, but you should make it something that makes sense. I usually name mine in the above convention - vl for VLAN, followed by the name / use of the vlan, followed by the physical interface. 2. create the bridges and add the vlans /interface bridge add name=laptops add name=pcs /interface bridge port add interface=vl-laptops-wds1 bridge=laptops add interface=vl-pc-wds1 bridge=pcs Note: leave the physical interface out of any bridges (in this case wds1) 3. add the ether interfaces to the appropriate vlans. In this