Running Check_Disk , Check_Procs, etc on remote systems

Hello,
I was wondering if it is possible to run commands that are labeled local on remote systems, or if there are equivalent commands to those that can be run on remote systems. In the services.cfg-sample, I found a sample that runs check-local-disk on different systems, but when I tried it on my configuration, it didn’t work, which makes sense since the check_disk command doesn’t take host address as an argument.
So is there a way to monitor remote systems with commands that give the same outputs as check_disk and others? and if it is possible, can the same commands (like check_disk) be run on non-linux systems?

Thank you very much for your time :slight_smile:

you may want to have a look at the various plugins like check_snmp. Have a look at NRPE and NCSA too for monitoring with nagios own local checks on a different server and sendin the results to the main server. For windows server check for nsClient.

Luca

nsClient did the job superbly! is there a similar plug-in that can be used to monitor other Linux and Solaris systems?
Thank you very much.

For Linux systems, you can use things like check_snmp, or use the NRPE or NSCA to run local checks on remote machines and have them sent to your Nagios server, like luca said.

Use NRPE to perform active checks from the nagios server to the remote linux box. If you have 1000’s of checks to perform, active checks are going to give you trouble. At some point, you should learn how to run passive checks. Meaning, the checks are performed on the remote machine, and sent to the central nagios server via some method like nsca. You could use a mini nagios setup, or a cron job to execute the checks on the remote machine.

oh now I see what he meant by NRPE :slight_smile: very good solution. thanks a lot
Is there by the way any plug-in that checks physical memory used/free for linux systems?
Thanks

Yes, there’s a check_mem command, and it should actually be available in the contrib/ directory you find after you unzip the file nagios-plugins.1.4.2.tar.tar.
Edited Thu Jan 05 2006, 10:28PM ]

Thanks a lot, it works great.
One last question, in order to run NRPE on a Solaris machine, I’d need to use the NRPE-solaris, right? I’ve tried to download it from nagiosexchange but it the file seems to be corrupt.
Should I use another solution to monitor Solaris machines, and if yes what is it? And what compilers do I need to have installed on solaris in order to get the plugins or NRPEs to work. I’ve tried to get some solaris plugins to run but they complained about gcc and cc, is that all I need to get installed on the machine?
Thanks a lot for your time. This is my first time to work on a unix system and nagios and I really appreciate the help so far.

Your solaris stuff can be messy, so be careful.
Solaris doesn’t come stock with a real cc. You will be able to find it, but it’s simply a script that says something like, “you don’t have it” or something weird like that. Anyway, solaris cc cost mega $$$ so it’s suggested you install gcc from that supplement disk that ships with solaris or download it. Then you can compile stuff. Most likely if logged in as root, you won’t have the path to make and other stuff defined (solaris does that in purpose). Anyway, you are going to run into many many little things in solaris, and I don’t care to name them all.

I hope you are a solaris admin there, and that they don’t mind you messin around. Otherwise, you might end up with a busted box.

Which Solaris version are you running? I am running nrpe on Solaris 9 and 10 without any problems.

I’m running nagios on many Solaris versions without a problem. But that wasn’t my point. I’ve found that you will run into many little problems when triing to compile something on Solaris and will have to install some packages like gcc. And that is what his last question was wondering about. i.e. compiling.

everythings working great now, thanks a lot :slight_smile:

i want to do some thing like LordGrahf has done,
i mean checking local resource on remote systems,
i 've tried to use NRPE , but i get this error :

CHECK_NRPE: Error - Could not complete SSL handshake.

how can i resolve it ?

CHECK_NRPE: Error - Could not complete SSL handshake was because of nrpe.cfg permissions , the error has gone !! but another has come !