Ad Widget

Collapse

Monitor daily backup process

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • MM20
    Junior Member
    • Mar 2019
    • 1

    #1

    Monitor daily backup process

    Hello,

    I will make my first steps with zabbix and I have a beginner question:

    I make a backup from a specific application on my linux server. This backup zip file I stored every day in a folder /media/usbstick/backup

    Now I want to monitoring, that every day there is a new file with today's creation date with size>0 in the folder /media/usbstick/backup.
    The access to the linux system is via SSH username/password or username/SSH key.
    If there is no today backup file, a trigger should send an alarm.

    How can this be done with zabbix?
    Thank you!
    Michael
  • jbezorg
    Junior Member
    • Aug 2017
    • 3

    #2
    You can use differnt ways to built that trigger. You could use the checksum of the file:
    Code:
    {host:vfs.file.cksum[/media/usbstick/backup].diff()}=1
    or you could use the file time:
    Code:
    {host:vfs.file.time[/media/usbstick/backup].now(0)}-{host:vfs.file.time[/media/usbstick/backup].last(0)}>86400
    where 86400 means 24 hours, so this trigger only is activated, if there is a change once a day.

    Comment

    • max.ch.88
      Senior Member
      • Oct 2018
      • 206

      #3
      I think it is more correct to send the result code of the backup script using zabbix_sender.

      Comment

      Working...