Shinken Monitoring - how to configure service checks on a host, for a specific time of the day

597 Views Asked by At

We are using Shinken Framework for monitoring our servers, in that I got a scenario like I want to execute a service check only once in a day that is everyday at 1 AM, how can I configure it?

Using check_interval or time_period can we achieve this..?

1

There are 1 best solutions below

2
Rohlik On BEST ANSWER

You need to set check_interval and check_period.
For example, we are using check at 9 AM everyday for check system updates. Just change time and service for your needs.

define timeperiod {
  timeperiod_name                morning_check
  alias                          morning_check
  monday                         09:00-09:01
  tuesday                        09:00-09:01
  wednesday                      09:00-09:01
  thursday                       09:00-09:01
  friday                         09:00-09:01
  saturday                       09:00-09:01
  sunday                         09:00-09:01
}

define service {
  service_description            updates
  host_name                      Docker
  use                            svc-pnp,local_standard_mail
  check_command                  ext_nrpe!check_updates!null
  check_period                   morning_check
  check_interval                 1440
  max_check_attempts             1
  notification_interval          1440
}