Hi,
I am trying to set alerts for swap usage.
I want alrets if 10 % is utilisaed as warning and 20% utilised as critical.
Now how do i set this ?
1. check_nrpe!check_swap!-a '-w 10 -c 20'
or
2. check_nrpe!check_swap!-a '-w 90 -c 80'
Thanks in advance.
swap usage
-
scottwilkerson
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: swap usage
check_nrpe!check_swap!-a '-w 90% -c 80%'
-
srikanth.kallu
- Posts: 243
- Joined: Thu Jul 26, 2012 10:48 am
Re: swap usage
i set the alert like this check_nrpe!check_swap!-a '-w 90% -c 80%' (First attachment)
But it still says Ok ( Second attachment )
Please correct me i dont understand my mistake.
But it still says Ok ( Second attachment )
Please correct me i dont understand my mistake.
You do not have the required permissions to view the files attached to this post.
-
srikanth.kallu
- Posts: 243
- Joined: Thu Jul 26, 2012 10:48 am
bug in checking swwap usage
Hi,
I think there is a bug in checking swap usage.
I have checked this on two of my servers AIX and LINUX
check_nrpe!check_swap!-a '-w 2 -c 1'
or check_nrpe!check_swap!-a '-w 100 -c 99'
but says status os Ok even if it is
SWAP OK - 81% free (820 MB out of 1023 MB)
I think there is a bug in checking swap usage.
I have checked this on two of my servers AIX and LINUX
check_nrpe!check_swap!-a '-w 2 -c 1'
or check_nrpe!check_swap!-a '-w 100 -c 99'
but says status os Ok even if it is
SWAP OK - 81% free (820 MB out of 1023 MB)
Re: swap usage
We are looking into this issue as we speak. We will do some testing and get back to you as soon as we determine what is causing it.
Be sure to check out our Knowledgebase for helpful articles and solutions!
-
sreinhardt
- -fno-stack-protector
- Posts: 4366
- Joined: Mon Nov 19, 2012 12:10 pm
Re: swap usage
This is not a bug, without adding % after each value, it is actually looking at bytes free not percentage. Please change your command to Try it out and let us know. Sorry for the confusion, scottwilkerson had it all correct in the first post.
Code: Select all
check_nrpe!check_swap!-a '-w 90% -c 80%'check_nrpe!check_swap!-a '-w 90% -c 80%'
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.