check_nrpe -c CheckProcState USING PID

Aki asked:

I’m currently running a SOLR search engine from a batch file and it appears as a process in my servers taskmgr. I need to monitor its state using check_nrpe but since there are more than one cmd.exe processes, I need to identify it using the PID of that process.

Can anyone provide me with an example syntax of how to do that? My syntax:

./check_nrpe -H IP -p port -c CheckProcState -a MinWarnCount=1 MinCritCount=0 cmd.exe (-ppid=2664)

The --ppid=2664 was just a lousy attempt to get it right but no results…

My answer:

Why don’t you use an actual Nagios plugin for solr? You’ll get much better results. And it will actually work. Icinga is perfectly capable of using Nagios plugins. Github has several to choose from…

View the full question and answer on Server Fault.

Creative Commons License
This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.