Disk Critical

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.
Metalliogre
Posts: 17
Joined: Mon Jun 02, 2014 6:57 pm

Re: Disk Critical

Post by Metalliogre »

I started following this tutorial on how to configure nagios to rid the 'critical disk error' and I am being asked to edit/create a checkcommand.cfg that I can't seem to find/do. Any help would be appreciated!
http://devincharge.com/quick-dirty-setup-nrpe-ubuntu/
Jeremiah Slagle,
JNB Productions

www.YouTube.com/JeremiahSlagle
@JupeBobby
sreinhardt
-fno-stack-protector
Posts: 4366
Joined: Mon Nov 19, 2012 12:10 pm

Re: Disk Critical

Post by sreinhardt »

That file is likely command.cfg instead of checkcommand.cfg. The naming is entirely arbitrary, but command.cfg is the defualt.
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.
Stuart Watts
Posts: 40
Joined: Wed Sep 25, 2013 7:01 am

Re: Disk Critical

Post by Stuart Watts »

The checks run as user "nagios" and you're attempting to check home directories, which "nagios" probably isn't allowed to traverse. You'd need to add an ACL (if possible) or slacken permissions to check these directories.
Metalliogre
Posts: 17
Joined: Mon Jun 02, 2014 6:57 pm

Re: Disk Critical

Post by Metalliogre »

Edited with no luck.
Jeremiah Slagle,
JNB Productions

www.YouTube.com/JeremiahSlagle
@JupeBobby
Metalliogre
Posts: 17
Joined: Mon Jun 02, 2014 6:57 pm

Re: Disk Critical

Post by Metalliogre »

How would I adjust permissions to allow the checks? I'm lost in Nagios.
Jeremiah Slagle,
JNB Productions

www.YouTube.com/JeremiahSlagle
@JupeBobby
User avatar
eloyd
Cool Title Here
Posts: 2129
Joined: Thu Sep 27, 2012 9:14 am
Location: Rochester, NY
Contact:

Re: Disk Critical

Post by eloyd »

It's not a Nagios answer, I'm afraid - it's an operating system answer. You need to be able to allow the user named "nagios" to check directories that are not owned by the user named "nagios." So you need to allow the user named "nagios" access to the directories using whatever appropriate security mechanism your OS allows.

(I'm saying user named "nagios" to avoid confusion with software called "Nagios.")
Image
Eric Loyd • http://everwatch.global • 844.240.EVER • @EricLoydI'm a Nagios Fanatic!
Metalliogre
Posts: 17
Joined: Mon Jun 02, 2014 6:57 pm

Re: Disk Critical

Post by Metalliogre »

I am running Ubuntu 12
Jeremiah Slagle,
JNB Productions

www.YouTube.com/JeremiahSlagle
@JupeBobby
User avatar
eloyd
Cool Title Here
Posts: 2129
Joined: Thu Sep 27, 2012 9:14 am
Location: Rochester, NY
Contact:

Re: Disk Critical

Post by eloyd »

EDIT: I didn't realize that this was page 2 of the comments, but I still think we've missed your actual check command and services entry.

I may have missed something, but I don't think we've seen the configuration that shows what the check is you're actually performing. Can you share that with us? services.cfg and checkcommands.cfg would be the default filenames that that information is in.
Last edited by eloyd on Thu Jun 05, 2014 11:34 am, edited 1 time in total.
Image
Eric Loyd • http://everwatch.global • 844.240.EVER • @EricLoydI'm a Nagios Fanatic!
Stuart Watts
Posts: 40
Joined: Wed Sep 25, 2013 7:01 am

Re: Disk Critical

Post by Stuart Watts »

The fact that these are .gvfs (Gnome Virtual File System?) mounts in home directories makes me think you've got something cool like networked home directories. If that's the case, the fileserver should hopefully be monitored already, so you could simply exclude those mount points from the check?

In your "commands.cfg", find the entry that relates to "check_all_disk". The comandline for this probably calls the plugin "check_disk". That plugin can be configured to ignore a mount point (-x), ignore a type of mount (-X), and even ignore mount points based on a regex (-r). Might be feasible to use one of these to ignore these checks?
sreinhardt
-fno-stack-protector
Posts: 4366
Joined: Mon Nov 19, 2012 12:10 pm

Re: Disk Critical

Post by sreinhardt »

Nice catch Stuart! Metal could you confirm if this is the case, and provide the current service and command definitions so that we may help you sort this out.
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.
Locked