Why this check run on Monday?


i have a check that checks a backuplog and as the backup not runs on weekends i have configured a check_period to avoid checks on sa-mo. But the check is executed on monday at 00:01. Any ideas why this is happening?



object Service "Assyst Backup Log" {
    host_name = "somehost"
    check_command = "powershell-windows"
    max_check_attempts = "2"
    check_period = "backup-check"
    check_interval = 15m
    retry_interval = 1m
    icon_image = "file.png"
    command_endpoint = host_name
    vars.deployment_status = "complete"
    vars.file_age = "1500"
    vars.filecontent_string = "Backup of assyst data and configuration finished successfully"
    vars.matchok = true
    vars.path = "E:\\ASSYST_BACKUP\\Log"
    vars.powershell_args = "-path \"$service.vars.path$\" -minutes \"$service.vars.file_age$\" -string '$service.vars.filecontent_string$' -matchOK"
    vars.powershell_scriptpath = "C:\\Program Files\\ICINGA2\\sbin\\check_filecontent.ps1"
    vars.sla = [ "none" ]


object TimePeriod "backup-check" {
    import "legacy-timeperiod"
    display_name = "backup-check"
    ranges = {
        "friday"	= "00:00-24:00"
        "thursday"	= "00:00-24:00"
        "tuesday"	= "00:00-24:00"
        "wednesday"	= "00:00-24:00"


did you check that all servers are in the same timzone. It could be also a a bug, time drigt between agent and master/satellite or simple the agent has a different configuration.
The last point could be check with icinga2 object list --type service --name 'somehost!Assyst Backup Log'
If everything is ok (time etc), i would open a issue over at github.


1 Like