Automate periodical DB Backup & monitor result of each

I’ve been tasked with automating the backup of our Databases onto a local NFS share, and more importantly than that monitor the result of each backup.

I’m absolutely green with Singlestore, but slowly getting to grips with it! (So please be gentle!)

I have the backup running to my NFS share manually, but need to now automate this (I suspect a Cron is the best method?)

How then when this is done can I output (to Zabbix or Email) the outcome of each backup?

Thanks in advance!

Hi Jon! :wave: Welcome aboard.

We’d love to help you with this. Can you let us know if you are running on the managed or self-hosted service? What version number please?


Hi Maria,

We are running a managed instance and it is version 5.7.32 that I am running in my testing!

Thank you for your response!


1 Like

My mistake, we’re actually using 7.8.10!

Can close this threat,

I’ve figured out a suitable solution for our purposes.

1 Like

Would you mind sharing? I have been monitoring this thread because i have the same issue.

1 Like

Awesome! :tada:

Yes, as I’m sure other’s can benefit from this thread.
Please share how you arrived to a solution.

Much appreciated! Thank you, Jon!

My solution was:

Use Cron to on a schedule query as below and output the results to a log file
memsql -h localhost -u user --password=YourPasswordHere -D INFORMATION_SCHEMA -e “SELECT * from INFORMATION_SCHEMA.MV_BACKUP_HISTORY order by END_TIMESTAMP desc LIMIT 1;” >> /tmp/cron_job.log

We use Zabbix as our main monitoring tool here, so with Zabbix you can set up an active agent on device to regularly check a log/text so we have it check for ‘success’ vfs.file.regmatch[/tmp/cron_job.log,Success] if it finds su

then set up a trigger to read the result (it’ll either be a 1 if it finds the word or a 0 if it does not) so you can tailor the trigger use the log file to periodically check that file and flag.


Thank You for sharing!