Here is a list of useful commands we use to debug a Mikrotik router
Backup
To backup a Mikrotik, you should do two types of backup, a config backup and RSC backup. In the Mikrotik CLI run the following commands to backup. A .backup is a binary file with user data and other metrics that might be captured. A .rsc file is a human readable format of the config. The .backup usually can only be restored back onto the same device where a .rsc can be modified to work with another model of Mikrotik router.
/system backup save name=backupname.backup
/export file=backupname.rsc
You will then see the backups in the Files List in the main screen of Winbox. You can then copy to a local directory on your machine.

Safe Mode
Safe mode can be used for changes, when safe mode is enabled the changes are made but not saved. If there is a problem and you are locked out of the router, you can reboot to revert the changes.
Safe mode is entered by pressing CTRL+X. To save changes and exit safe mode, press CTRL+X again. To exit without saving the made changes, press CTRL+D
Routing
Show the route taken to reach a destination where 111.111.111.111 is the destination address (takes a while with BGP)
# Option 1, standard /ip route print where 111.111.111.111 in dst-address # Option 2, faster (requires known ip and /mask). # The IP address and netmask can be taken from a whois e.g. whois 8.8.8.8 and look for CIDR 8.0.0.0/9 /ip route print detail where dst-address=111.111.111.111/11 # Print BGP advertisements to remote peers (e.g. to a border or other core router) /routing bgp advertisements print
When you want to change route for a particular subnet, you would add a static route and change the preference to a higher value
/ip route add dst-address=111.111.111.0/16 gateway=10.0.11.1 bgp-local-pref=200 # Example - Taken from https://wiki.mikrotik.com/wiki/Manual:BGP_Case_Studies /ip route print where 111.111.111.111 in dst-address /ip route add dst-address=111.111.111.111/32 gateway=10.0.11.1 bgp-local-pref=200 # Example to remove the route /ip route remove [find address="111.111.111.111/32"]
Bandwidth Tests
You can use the inbuild bandwidth test inside Winbox to test the speed of your internet connection. To access this, go into Winbox, select Tools => Bandwidth Test

Here is a list of public bandwidth servers;
| Name |
Location |
IP Address | Username / Password | Notes |
| Tom Jones | North Idaho - United States | 23.162.144.120 2605:6340:0:1b::4 |
btest / btest | Capable of running bandwidth tests of up to 4Gb/s |
Test DNS resolution
You can use the following command to resolve DNS and a specific DNS server. In this example, we are using CloudFlare 1.1.1.1 as the resolver and trying to resolve domain.com. The return value should be the IP address of the domain name.
:put [:resolve server=1.1.1.1 domain-name=domain.com]