LinuxQuestions.org
Did you know LQ has a Linux Hardware Compatibility List?
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices

Reply
 
Search this Thread
Old 01-05-2010, 01:08 AM   #1
prak86
LQ Newbie
 
Registered: Dec 2009
Posts: 21

Rep: Reputation: 15
How to change Threshold time in nagios services


Hi,
I have installed nagios in a CentOS vm and now its monitoring the local host, one remote host which is also a vm with CentOS 5.3 and one windows xp system.

Is there any option for me to change the threshold time for the services given?
for eg;

i had a service of current_load which comes as a default plugin while installing nagios itself. what should i do to change the threshold value of the current_load so that i might get the warning or error alert some time earlier as it was now.

I am new to this nagios, can anyone let me know the procedures to change the threshold time......
 
Old 01-05-2010, 02:23 AM   #2
Lee_Ball
Member
 
Registered: Jul 2005
Location: Manchester (UK)
Distribution: Fedora CentOS
Posts: 132

Rep: Reputation: 18
there are normally entries in the config files that look like 10!20! etc, these are the different settings. Now I don't know if thats 10% and 20% or if they are assigned values.

There is another config file which has something like !w!a or something like that. Essentially I believe the numbers are applied between the lines. Have a poke around in the configs, its in there somewhere, I don't have easy access to a Nagios machine at the moment.
 
Old 01-05-2010, 11:19 PM   #3
prak86
LQ Newbie
 
Registered: Dec 2009
Posts: 21

Original Poster
Rep: Reputation: 15
Hi,

I found a file in the remote host named nrpe.cfg , i am not sure this is the file you are mentioning about and in this file i found some lines like

# The following examples use hardcoded command arguments...

command[check_users]=/usr/local/nagios/libexec/check_users -w 5 -c 10
command[check_load]=/usr/local/nagios/libexec/check_load -w 15,10,5 -c 30,25,20
command[check_hda1]=/usr/local/nagios/libexec/check_disk -w 20% -c 10% -p /dev/hda1
command[check_zombie_procs]=/usr/local/nagios/libexec/check_procs -w 5 -c 10 -s Z
command[check_total_procs]=/usr/local/nagios/libexec/check_procs -w 150 -c 200


# The following examples allow user-supplied arguments and can
# only be used if the NRPE daemon was compiled with support for
# command arguments *AND* the dont_blame_nrpe directive in this
# config file is set to '1'. This poses a potential security risk, so
# make sure you read the SECURITY file before doing this.

#command[check_users]=/usr/local/nagios/libexec/check_users -w $ARG1$ -c $ARG2$
#command[check_load]=/usr/local/nagios/libexec/check_load -w $ARG1$ -c $ARG2$
#command[check_disk]=/usr/local/nagios/libexec/check_disk -w $ARG1$ -c $ARG2$ -p $ARG3$
#command[check_procs]=/usr/local/nagios/libexec/check_procs -w $ARG1$ -c $ARG2$ -s $ARG3$


As per my understanding w is for warning and c is for critical, but i cant understand what those numbers are for.

In the case of current_load the numbers 15,10,5 are meant for minutes or for the percentage?
will the threshold value get affected by changing this values?
 
Old 01-06-2010, 02:18 AM   #4
Lee_Ball
Member
 
Registered: Jul 2005
Location: Manchester (UK)
Distribution: Fedora CentOS
Posts: 132

Rep: Reputation: 18
The nrpe file should only effect those hosts being checked using nrpe. Which in the case of a remote Linux host is likely.

See if this helps:

http://www.linuxquestions.org/questi...riables-61350/
 
Old 01-11-2010, 02:59 AM   #5
centosboy
Senior Member
 
Registered: May 2009
Location: london
Distribution: centos5
Posts: 1,137

Rep: Reputation: 116Reputation: 116
Quote:
Originally Posted by prak86 View Post
Hi,

I found a file in the remote host named nrpe.cfg , i am not sure this is the file you are mentioning about and in this file i found some lines like

# The following examples use hardcoded command arguments...

command[check_users]=/usr/local/nagios/libexec/check_users -w 5 -c 10
command[check_load]=/usr/local/nagios/libexec/check_load -w 15,10,5 -c 30,25,20
command[check_hda1]=/usr/local/nagios/libexec/check_disk -w 20% -c 10% -p /dev/hda1
command[check_zombie_procs]=/usr/local/nagios/libexec/check_procs -w 5 -c 10 -s Z
command[check_total_procs]=/usr/local/nagios/libexec/check_procs -w 150 -c 200


# The following examples allow user-supplied arguments and can
# only be used if the NRPE daemon was compiled with support for
# command arguments *AND* the dont_blame_nrpe directive in this
# config file is set to '1'. This poses a potential security risk, so
# make sure you read the SECURITY file before doing this.

#command[check_users]=/usr/local/nagios/libexec/check_users -w $ARG1$ -c $ARG2$
#command[check_load]=/usr/local/nagios/libexec/check_load -w $ARG1$ -c $ARG2$
#command[check_disk]=/usr/local/nagios/libexec/check_disk -w $ARG1$ -c $ARG2$ -p $ARG3$
#command[check_procs]=/usr/local/nagios/libexec/check_procs -w $ARG1$ -c $ARG2$ -s $ARG3$


As per my understanding w is for warning and c is for critical, but i cant understand what those numbers are for.

In the case of current_load the numbers 15,10,5 are meant for minutes or for the percentage?
will the threshold value get affected by changing this values?


it is easy to find out what these numbers are for by actually running the command on the command line without some of the parameters. Then an explanation will pop up that shows which is for which and giving an example.
This only applies if you are actually using nrpe to do these checks.
nagios can be a bit of a pain...one of the things you have to either look at logically OR read the instructions. i learnt this the hard way
 
Old 05-03-2011, 02:43 AM   #6
arunsharma8466
LQ Newbie
 
Registered: Apr 2011
Posts: 1

Rep: Reputation: 0
Smile Thersold define in nagios

Hello Friends,
I have nagios server in debiana and linux 5.

Two question is arise >> can we define thersold in nagios server? .. plz give me qnswer . how we define?


Thanks & Regards
Arun Sharma
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Nagios: Check backupexec services on windows server TalkingMarble Linux - Software 4 11-11-2009 02:14 AM
LXer: Fixing your network the lazy way - using nagios to build self healing services LXer Syndicated Linux News 0 04-07-2009 04:30 PM
LXer: Tutorial: Keep Tabs on Network Services with Nagios, Pt. 2 LXer Syndicated Linux News 0 06-19-2006 09:54 PM
LXer: Tutorial: Keep Tabs on Network Services with Nagios LXer Syndicated Linux News 0 06-18-2006 11:21 AM
LXer: Keep Tabs on Network Services with Nagios LXer Syndicated Linux News 0 04-29-2006 04:21 PM


All times are GMT -5. The time now is 04:07 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration