[solved] nagios - web view doesn't agree with CLI checks

I use the ssh public key for nagios to monitor resources on a remote server.

All checks work from the command line on the remote server, and from the nagios server command line.

However, about 20 of the file system checks on the remote server show up in the nagios web display as “A file or directory in the path name does not exist.” The other 10 file systems checks display correctly. Even though I can issue the same check (copied from the config file) from the nagios command line via ssh to the remote server and the check works, displaying the disk space used…

Any clue why this may be happening? I can provide more details if necessary.

  • Tom Rutledge

Can you post your command (from command.cfg) it might be that if you use the whole path istead of $USER1$ it will work. But it can be alot more then that. Can’t say for sure until you can show more info :slight_smile:

here is the line from my config file that does NOT display properly in the web:

check_command check_by_ssh!"/usr/local/nagios/libexec/check_disk -w 10% -c 5% -p /db2_backup"

and here is one that DOES display properly in the web:

check_command check_by_ssh!"/usr/local/nagios/libexec/check_disk -w 10% -c 5% -p / "

I have changed the order of these commands (put the one that does NOT display correct first, then later), but it does not make a difference.

(NOTE: the remote system is an AIX 6.1 system.)

Thanks for any guidance you can provide.

Hi Rut,

Take a look at: http://forums.meulie.net/t/check-disk-plugin-not-reporting-on-mounted-filesystem/3435
That looks like the same problem, which results in just userrights on the mounted fs.

Unfortunately, that link does not help. The nagios id can run the command on the remote server, and the results are good, plus, the nagios id on the nagios server can run the command (on the command line) and get the proper results. The problem is the command does NOT work in the web server - that results in a “A file or directory in the path name does not exist” message being shown in the Status Info column, and a CRITICAL status.

Thank you for the link, though.

Anyone with AIX experience out there? Maybe it is the way AIX has mounted the file systems? (Although I cannot figure out why that would make a difference for the web display.

  • TheRut

Found the problem - when I created the config file for this server, I cloned it from another server with similar services. And then I did not change the host IP# - so, this check was for a system that did NOT have these file systems, and the web view was only doing what it should. (My command line checks were all to the correct server, but the web used the IP# in the config file, which was wrong.)

Therefore, the move to AIX 6x was entirely unrelated.