Configuration Management


General Information


This manual introduces you with commands which are used to perform the following functios:


The configuration backup can be used for backing up MikroTik RouterOS configuration to a binary file, which can be stored on the router or downloaded from it using FTP. The configuration restore can be used for restoring the router's configuration from a backup file.

The configuration export can be used for dumping out MikroTik RouterOS configuration to the console screen or to a text (script) file, which can be downloaded from the router using FTP. The configuration import can be used to import the router configuration script from a text file.

System reset command is used to erase all configuration on the router. Before doing that, it might be useful to backup the router's configuration.

Note! In order to be sure that the backup will not fail, system backup load command must be used on the same computer with the same hardware where system backup save was done.


System Backup

Submenu level: /system backup


The save command is used to store the entire router configuration in a backup file. The file is shown in the /file submenu. It can be downloaded via ftp to keep it as a backup for your configuration.

To restore the system configuration, for example, after a /system reset, it is possible to upload that file via ftp and load that backup file using load command in /system backup submenu.

Command Description

load name=[filename] - Load configuration backup from a file

save name=[filename] - Save configuration backup to a file


To save the router configuration to file test:

[admin@MikroTik] system backup> save name=test

Configuration backup saved

[admin@MikroTik] system backup>

To see the files stored on the router:

[admin@MikroTik] > file print

  # NAME                           TYPE         SIZE       CREATION-TIME

  0 test.backup                    backup       12567      aug/12/2002 21:07:50

[admin@MikroTik] >


To load the saved backup file test:

[admin@MikroTik] system backup> load name=test

Restore and reboot? [y/N]: y



The Export Command

Command name: export


The export command prints a script that can be used to restore configuration. The command can be invoked at any menu level, and it acts for that menu level and all menu levels below it. If the argument from is used, then it is possible to export only specified items. In this case export does not descend recursively through the command hierarchy. export also has the argument file, which allows you to save the script in a file on the router to retrieve it later via FTP.

Command Description

from=[number] - specifies from which item to start to generate the export file

file=[filename] - saves the export to a file


[admin@MikroTik] > ip address print

Flags: X - disabled, I - invalid, D - dynamic

 #   ADDRESS            NETWORK         BROADCAST       INTERFACE

 0      bridge1

 1      ether1

[admin@MikroTik] >

To make an export file:

[admin@MikroTik] ip address> export file=address

[admin@MikroTik] ip address>

To make an export file from only one item:

[admin@MikroTik] ip address> export file=address1 from=1

[admin@MikroTik] ip address>

To see the files stored on the router:

[admin@MikroTik] > file print

 # NAME                            TYPE         SIZE       CREATION-TIME

0  address.rsc                     script       315        dec/23/2003 13:21:48

1  address1.rsc                    script       201        dec/23/2003 13:22:57

[admin@MikroTik] >

To export the setting on the display use the same command without the file argument:

[admin@MikroTik] ip address> export from=0,1

# dec/23/2003 13:25:30 by RouterOS 2.8beta12

# software id = MGJ4-MAN


/ ip address

add address= network= broadcast= \

    interface=bridge1 comment="" disabled=no

add address= network= broadcast= \

    interface=ether1 comment="" disabled=no

[admin@MikroTik] ip address>


The Import Command

Submenu level: /import


The root level command /import file_name restores the exported information from the specified file. This is used to restore configuration or part of it after a /system reset event or anything that causes configuration data loss.

Note that it is impossible to import the whole router configuration using this feature. It can only be used to import a part of configuration (for example, firewall rules) in order to spare you some typing.

Command Description

file=[filename] - loads the exported configuration from a file to router


To load the saved export file use the following command:

[admin@MikroTik] > import address.rsc

Opening script file address.rsc

Script file loaded successfully

[admin@MikroTik] >


Configuration Reset

Submenu level: /system


The command clears all configuration of the router and sets it to the default including the login name and password ('admin' and no password), IP addresses and other configuration is erased, interfaces will become disabled. After the reset command router will reboot.

Property Description

keep-user-config (yes | no; default: no) - whether to keep entries in '/user' list or not

Command Description

reset - erases router's configuration


[admin@MikroTik] > system reset

Dangerous! Reset anyway? [y/N]: n

action cancelled

[admin@MikroTik] >