How to monitor long running processes?

An open discussion forum for obtaining help with Nagios Core. Nagios Core users of all experience levels are welcome here. Subforum have been created for the discussion of Nagios Core and Nagios Plugin development.

NOTE: The SourceForge.net mailing lists have been deprecated in favor of this forum in order to expedite support and provide additional features not available on the old mailing list.

How to monitor long running processes?

Postby Siddharth Hegde » Fri Sep 14, 2018 6:11 am

Hello,

I have couple of long running processes in server which runs for days at stretch. Is there a way to get alerts when they stop or exit? How to monitor them in NRPE?

Regards,
Siddarth Hegde
Siddharth Hegde
 
Posts: 41
Joined: Mon Aug 07, 2017 4:19 am

Re: How to monitor long running processes?

Postby npolovenko » Fri Sep 14, 2018 12:03 pm

@Siddharth Hegde, Are you looking to monitor processes on a windows server or on a linux server? You can find some examples here:
https://support.nagios.com/kb/article/process-checks-782.html
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
User avatar
npolovenko
Support Tech
 
Posts: 2035
Joined: Mon May 15, 2017 5:00 pm

Re: How to monitor long running processes?

Postby Siddharth Hegde » Fri Sep 14, 2018 12:10 pm

Hi @npolovenko,

All are ubuntu 16.04 servers

Thanks,
Siddarth Hegde
Siddharth Hegde
 
Posts: 41
Joined: Mon Aug 07, 2017 4:19 am

Re: How to monitor long running processes?

Postby npolovenko » Fri Sep 14, 2018 1:07 pm

@Siddharth Hegde, You can use the check_procs plugin. Put the following command in the nrpe.cfg file on the Ubuntu server.
command[check_process]=/usr/local/nagios/libexec/check_procs $ARG1$

And here's the command to run from the Nagios server.
/usr/local/nagios/libexec/check_nrpe -H IP_address -c check_process -a "-a httpd -c 2:5"

You can replace httpd with the name of the process you want to monitor. And you can replace my current critical range 2:5 with your own. Meaning that the plugin will return in Critical state if there are 2 to 5 httpd processes running on the Ubuntu server.
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
User avatar
npolovenko
Support Tech
 
Posts: 2035
Joined: Mon May 15, 2017 5:00 pm

Re: How to monitor long running processes?

Postby Siddharth Hegde » Sat Sep 15, 2018 1:29 am

Hi @npolovenko,

Thanks. I will check it

Regards,
Siddarth Hegde
Siddharth Hegde
 
Posts: 41
Joined: Mon Aug 07, 2017 4:19 am

Re: How to monitor long running processes?

Postby scottwilkerson » Mon Sep 17, 2018 8:32 am

Siddharth Hegde wrote:Hi @npolovenko,

Thanks. I will check it

Regards,
Siddarth Hegde


Let us know if we can be of further assistance
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
User avatar
scottwilkerson
DevOps Engineer
 
Posts: 11679
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises


Return to Nagios Core

Who is online

Users browsing this forum: berlin and 36 guests