Send backup configuration through gmail

Source: http://adamonline.web.id/mikrotik/cara-setting-email-di-mikrotik
[admin@MikroTik] > /tool e-mail set address=[:resolve smtp.gmail.com] from=user@gmail.com password=secretpwd port=587 start-tls=yes user=user@gmail.com
-to test sending an email
/tool e-mail send to=user@gmail.com subject=”test send email from mikrotik” body=”ok” start-tls=yes

/system script
add name=system.backup source={/system backup save name=system;
/tool e-mail send to=”user@gmail.com” subject=([/system identity get name]” system backup”) body=”$[/system clock get date] system backup” file=system.backup;}

/system scheduler
add comment=”” disabled=no interval=7d name=”system.backup” \
on-event=system.backup start-date=jan/01/1970 start-time=00:00:00

/system script
add name=config.backup source={/export file=config;
/tool e-mail send to=”user@gmail.com” subject=([/system identity get name]” config backup”) body=”$[/system clock get date] config backup” file=config.rsc;}

/system scheduler
add comment=”” disabled=no interval=7d name=”config.backup” \
on-event=config.backup start-date=jan/01/1970 start-time=00:00:00

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s