escalation not works

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
User avatar
gshergill
Posts: 231
Joined: Tue Aug 07, 2012 5:08 am

Re: escalation not works

Post by gshergill »

Hi niraj_vara,

Your local.cfg just has the service escalations defined?

I can't see anything wrong with what you have posted... It's odd that the escalation isn't in the logs.

I literally copy and pasted your service escalation into my config file and it worked fine.

When you run the command below do any errors appear?

Code: Select all

/usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg
All I can recommend is to make sure the file with the escalations defined is in nagios.cfg.

Kind Regards,

Gary Shergill
niraj_vara
Posts: 20
Joined: Thu Dec 13, 2012 1:38 am

Re: escalation not works

Post by niraj_vara »

Hi gary
I have run the following command and there is no error !!!

in my local.cfg I have the following three entries

define service{
use local-service ; Name of service template to use
host_name localhost
service_description Root Partition
#check_command check_local_disk!50%!40%!/
check_command check_local_disk!20%!10%!/
contact_groups sms
}

define serviceescalation{
host_name localhost
service_description Root Partition
first_notification 3
last_notification 5
contact_groups admins
notification_interval 10
# escalation_period 24x7
# escalation_options w,u,c,r
}

define serviceescalation{
host_name localhost
service_description Root Partition
first_notification 6
last_notification 8
contact_groups admins,escalation
notification_interval 10

}


when I set the root partition warning my contact group sms is able to received the trigger but its not able to reach to the serviceescalation definition.
User avatar
gshergill
Posts: 231
Joined: Tue Aug 07, 2012 5:08 am

Re: escalation not works

Post by gshergill »

Hi niraj_vara,

Does your nagios.cfg file has the following (with the appropriate path)?

Code: Select all

cfg_file=/usr/local/nagios/etc/objects/local.cfg
Can you post your local-service template? Root Partition is using local-service not generic-service.

To speed things up maybe try using lower notification/check intervals (I use 1 minute for testing).

Are you receiving all notifications to the group sms? Or where does the 3rd/4th/5th notification go?

I've just copy and pasted your local.cfg to a new file local.cfg on my system. I added it to nagios.cfg and changed the contact_groups to some new test ones I created.
I changed all notification and check_intervals to 1 minute and everything worked fine (both escalations were initiated).

So there's definitely nothing wrong with the configurations you have just posted, the problem lies elsewhere.

Kind Regards,

Gary Shergill
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: escalation not works

Post by scottwilkerson »

Again, as gshergill asked:
gshergill wrote:Just to check, you mentioned before that the local.cfg is where you have defined the escalations? Have you added this .cfg to your nagios.cfg?
Former Nagios employee
Creator:
ahumandesign.com
enneagrams.com
niraj_vara
Posts: 20
Joined: Thu Dec 13, 2012 1:38 am

Re: escalation not works

Post by niraj_vara »

Hi Gary

Thnks for your help. I have tried the same with configuration and notification/check intervals changed to 2 minute .

Now its working fine.
sreinhardt
-fno-stack-protector
Posts: 4366
Joined: Mon Nov 19, 2012 12:10 pm

Re: escalation not works

Post by sreinhardt »

Great! Are you all set then niraj_vara?
Nagios-Plugins maintainer exclusively, unless you have other C language bugs with open-source nagios projects, then I am happy to help! Please pm or use other communication to alert me to issues as I no longer track the forum.
niraj_vara
Posts: 20
Joined: Thu Dec 13, 2012 1:38 am

Re: escalation not works

Post by niraj_vara »

Hi Srein

In nagios I had installed 8 live servers long time ago. and it was working the perfectly with e-mail and sms triggered.

Recently I was just trying for the escalation and in that I had issue. but now its working fine.

thnks you all for help and guidance.
Locked