NagiosXi - Time periods ranges
-
Bala.Mutyam
- Posts: 97
- Joined: Wed Apr 29, 2020 12:18 pm
NagiosXi - Time periods ranges
Hi,
Is it possible to include Time period ranges like Monday - Friday as Time Definition and 07:00-19:00 as Time Range. I have tired but giving an error "Error: Could not parse timerange #1 for day 1 of timeperiod (config file '/usr/local/nagios/etc/timeperiods.cfg', starting on line 53)" .
Also can we also have run checks for 24/7 but send alerts for a particular time period (say 0:700-19:00) and for a specific group?
Is it possible to include Time period ranges like Monday - Friday as Time Definition and 07:00-19:00 as Time Range. I have tired but giving an error "Error: Could not parse timerange #1 for day 1 of timeperiod (config file '/usr/local/nagios/etc/timeperiods.cfg', starting on line 53)" .
Also can we also have run checks for 24/7 but send alerts for a particular time period (say 0:700-19:00) and for a specific group?
You do not have the required permissions to view the files attached to this post.
-
scottwilkerson
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: NagiosXi - Time periods ranges
monday - friday wouldn't be valid, you would need to add each day separately.
There are a lot of different ranges that are valid but that isn't one that exists
See:
https://assets.nagios.com/downloads/nag ... riods.html
There are a lot of different ranges that are valid but that isn't one that exists
See:
https://assets.nagios.com/downloads/nag ... riods.html
-
Bala.Mutyam
- Posts: 97
- Joined: Wed Apr 29, 2020 12:18 pm
Re: NagiosXi - Time periods ranges
@scottwilkerson - Thanks for the update.
Also possible to run checks for 24/7 and only send alerts between 7:00-19:00 for a particular hostgroups?
Also possible to run checks for 24/7 and only send alerts between 7:00-19:00 for a particular hostgroups?
Last edited by Bala.Mutyam on Mon Jul 06, 2020 10:43 am, edited 1 time in total.
-
scottwilkerson
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: NagiosXi - Time periods ranges
Yes, you can set a separate time-period for notifications when editing a host/service in the CCM
Alert Settings Tab -> Notification period
Alert Settings Tab -> Notification period
-
Bala.Mutyam
- Posts: 97
- Joined: Wed Apr 29, 2020 12:18 pm
Re: NagiosXi - Time periods ranges
@scottwilkerson - Thanks for the update.
For some reason notification is not working.
Here are the definitions:
timeperiod:
Service:
contactsgroup:
As per the definitions, we are supposed to receive alerts from 7am to 7pm but we are not receiving any alerts? please have a look.
Thannks
For some reason notification is not working.
Here are the definitions:
timeperiod:
Code: Select all
define timeperiod {
timeperiod_name cp-standard-timeperiod
alias CP standard timings
monday 07:00-19:00
tuesday 07:00-19:00
wednesday 07:00-19:00
thursday 07:00-19:00
friday 07:00-19:00
}
Code: Select all
define service {
host_name server_name
service_description Local Disks
check_command check_xi_ncpa!-t 'NagiosXi' -P 5693 -M 'plugins/check_disk' -q 'args=-l -w 20% -c 10%'
max_check_attempts 2
check_interval 5
retry_interval 1
check_period 24x7
notification_interval 5
notification_period cp-standard-timeperiod
contact_groups Linux-Alerts
register 1
}
Code: Select all
define contactgroup {
contactgroup_name Linux-Alerts
alias Linux Systems Alerts
members member1,member2
}
Thannks
-
scottwilkerson
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: NagiosXi - Time periods ranges
Do the notification events show up in the Notification Log & State History?
-
Bala.Mutyam
- Posts: 97
- Joined: Wed Apr 29, 2020 12:18 pm
Re: NagiosXi - Time periods ranges
I can see events in the Notifications but nothing in state log on NagiosXi under Reports.
-
scottwilkerson
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: NagiosXi - Time periods ranges
Are the notifications for member1,member2 on server_name Local Disks?
-
scottwilkerson
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: NagiosXi - Time periods ranges
Can you verify that member1 and member2 have all the correct items set in their Notification settings, see page 2,3 here
https://assets.nagios.com/downloads/nag ... ios-XI.pdf
make sure the notification method and preferences are set to receive the types you want.
https://assets.nagios.com/downloads/nag ... ios-XI.pdf
make sure the notification method and preferences are set to receive the types you want.