This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
networking:router:mikrotik_backup [2019/08/27 09:07] gcooper |
networking:router:mikrotik_backup [2022/11/22 14:25] (current) gcooper |
||
---|---|---|---|
Line 12: | Line 12: | ||
Export section by section and import one section at a time. | Export section by section and import one section at a time. | ||
+ | |||
+ | ===== Automated Backup ===== | ||
+ | |||
+ | {{: | ||
+ | |||
+ | ==== E-Mail Settings ==== | ||
+ | |||
+ | Sending e-mail is sensitive due to security. | ||
+ | |||
+ | < | ||
+ | # Edit Mail Settings | ||
+ | :local emailserverip " | ||
+ | :local emailfrom "XYZ Router < | ||
+ | :local emailto " | ||
+ | :local emailusername " | ||
+ | :local emailpassword " | ||
+ | |||
+ | /tool e-mail set from=" | ||
+ | | ||
+ | </ | ||
+ | |||
+ | ==== makebackup Script ==== | ||
+ | |||
+ | < | ||
+ | # Automatic backup script | ||
+ | :log info " | ||
+ | :local SYSname [/system identity get name]; | ||
+ | :put " | ||
+ | /system backup save name=" | ||
+ | /export file=" | ||
+ | :log info " | ||
+ | :delay 10s; | ||
+ | :log info " | ||
+ | :local files {($SYSname . " | ||
+ | /tool e-mail send to=" | ||
+ | body=" | ||
+ | :log info " | ||
+ | :delay 10s; | ||
+ | :log info " | ||
+ | :put " | ||
+ | /file remove ($SYSname . " | ||
+ | /file remove ($SYSname . " | ||
+ | :log info " | ||
+ | </ |