Check_disk usage for linux servers

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
naranant
Posts: 90
Joined: Tue Oct 24, 2017 10:50 am

Check_disk usage for linux servers

Post by naranant »

Hi,

I am trying to monitor the file system usage in the Linux environment but not able to figure out the usage of the right syntax.

Below is one of the example where the usage is 99% but still getting the result as Disk ok.. Ideally i need to get the critical alert when the disk usage is above 95%.

[[email protected] ~]$ /usr/local/nagios/libexec/check_nrpe -H 1Xx.xx.Xxx.1xx -t 30 -c check_disk -a '/app/testjpl -w 10 -c 5'
DISK OK - free space: /app/testjpl 52 MB (1% inode=99%);| /app/testjpl=4602MB;;;0;4911
User avatar
cdienger
Support Tech
Posts: 5045
Joined: Tue Feb 07, 2017 11:26 am

Re: Check_disk usage for linux servers

Post by cdienger »

I believe the path should be at the end. Try the following:

/usr/local/nagios/libexec/check_nrpe -H 1Xx.xx.Xxx.1xx -t 30 -c check_disk -a '-w 10% -c 5% /app/testjpl'
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
naranant
Posts: 90
Joined: Tue Oct 24, 2017 10:50 am

Re: Check_disk usage for linux servers

Post by naranant »

I have tried with that option also but in spite of 98% usage, the disk still shows as ok.


[[email protected] ~]$ /usr/local/nagios/libexec/check_nrpe -H 1X.x.xx.xx -t 30 -c check_disk -a '-w 10% -c 5% /app'
DISK OK - free space: /app 47504 MB (98% inode=98%);| /app=618MB;45241;47754;0;50268
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Check_disk usage for linux servers

Post by lmiltchev »

According to the plugin's output, you should have 98% free space on /app... Can you run the following commands on the remote machine and show the output?

Code: Select all

mount
df -h
/usr/local/nagios/libexec/check_disk -w 10% -c 5% -p /app
Note: Modify the path to the check_disk plugin if it's different on your system.
Be sure to check out our Knowledgebase for helpful articles and solutions!
naranant
Posts: 90
Joined: Tue Oct 24, 2017 10:50 am

Re: Check_disk usage for linux servers

Post by naranant »

@lmiltchev : I was reading the output wrong it worked for me after putting the path at the end of the command. Thank you all for your help.
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Check_disk usage for linux servers

Post by lmiltchev »

Great! I am glad your issue has been resolved! I will be closing this topic now. If you have any more questions/issues, please start a new thread.
Be sure to check out our Knowledgebase for helpful articles and solutions!
Locked