Mikrotik – Upgrade RouterOS from the Command Line

My Mikrotik router was running version 6.30 which I needed to update to version 6.31 in order to support RSA keys. I found updating the router from the command line to be quite easy an straight forward. it only requires a few commands and requires little user input.

I know of two ways to view the current running firmware. My hAP at the time it arrived was running RouterOS version 6.30.4.

[admin@HM-GW] /system resource> print
                   uptime: 14h43m39s
                  version: 6.30.4
               build-time: Aug/25/2015 12:59:46
              free-memory: 41.0MiB
             total-memory: 64.0MiB
                      cpu: MIPS 24Kc V7.4
                cpu-count: 1
            cpu-frequency: 650MHz
                 cpu-load: 3%
           free-hdd-space: 4.8MiB
          total-hdd-space: 16.0MiB
  write-sect-since-reboot: 691
         write-sect-total: 5566
               bad-blocks: 0%
        architecture-name: mipsbe
               board-name: hAP ac lite
                 platform: MikroTik

Making use of the /system package update check-for-updates we can also view the running version and latest available version of RouterOS for download.

[admin@HM-GW] /system package update> check-for-updates
   current-version: 6.30.4
   latest-version: 6.34.3

Now that we know there is an available update we tell the router to download and install. The router will reboot.

[admin@HM-GW] /system package update> download
          channel: current
  current-version: 6.34.3
   latest-version: 6.34.4
           status: Downloaded, please reboot router to upgrade it

Reboot for the changes to take effect.

[admin@HM-GW] /system package update> /system reboot

You will be asked for confirmation prior to rebooting.

Reboot, yes? [y/N]:
system will reboot shortly

Installing the new firmware took less than a minute. Let’s check again and see what version of RouterOS is currently running.

[admin@HM-GW] /system package update> check-for-updates
          channel: current
  current-version: 6.34.3
   latest-version: 6.34.3
           status: System is already up to date

We are done and the system is now updated to the latest available firmware. Fairly easy and painless to update RouterOS.

4/8/2016 – Corrected grammatical error. Thank you for pointing it out.