Load specified backup after boot

Hello Guys,

Is there possibility to instruct RouterOS to load specified configuration after boot. My intention is to have some sane protection against configuration mistakes. For example say I’m configuring firewall remotely and I will make a mistake so I’d like boot with a previous configuration. Is this possible with Mikrotik RouterOS?
I know maybe one possiblity would be to schedule loading of backup after some time..
I’m missing this feature in RouterOs like you have with Cisco or other network equipment that you have running configuration and boot configuration so you need actually to save configuration to screw up whole router so you have always possibility to send there someone just to unplug and plug router to electricity. Here everything you do is applied to boot configuration.

Thanks for advice,
Regards,
Vlado

You can.

Write a simple script that effectively does this;

:delay 2m
/system backup load name=MikroTik-vanilla-backup

The delay is there to allow you to login and stop it if you inadvertently reboot the router.

Then create a schedule item that references the script to run at bootup.

I would also write some sort of script that sends a message to you when the router is rebooted because in the event of a power failure, your router will after 2 minutes revert back to your vanilla backup.

I’m sure I’ve missed something but it’s something to work with.

Hope this helps.

i would suggest to use safe mode, so when you configure something - and you disconnect from router - changes get reverted back.

Agreed, safe mode has saved my ass a few times now.

Thanks Guys for suggestions,

I didn’t know that there is such nice feature like safe mode in RouterOs.
Do you know whether it will unroll changes also if you reboot system while you have safe mode sill open?

Vlado.

Yes that’s the point of it. In a new terminal session, just press ctrl+x to enable safe mode, then if you’re sure you want to commit the changes, press ctrl+x again to commit the changes.

Else reboot to release them.

Try it out.