monitoring a service with a parameter

Engage with the community of users including those using the open source solutions.
Includes Nagios Core, Plugins, and NCPA

monitoring a service with a parameter

Postby gatorcb » Tue May 07, 2013 11:59 am

We have the need to monitor an ldpservice the windows path and parameter are C:\Windows\System32\svchost.exe -k LPDService How do you go about setting nagios to watch the health of the service since lots of other things using svchost, so checking the exe is not an option?

Thanks
gatorcb
 
Posts: 3
Joined: Tue May 07, 2013 11:52 am

Re: monitoring a service with a parameter

Postby slansing » Tue May 07, 2013 12:46 pm

You should be able to find the active directory service under services in "services.msc" rather than trying to monitor it under the svchost process you can cut directly to the service.
slansing
 
Posts: 7698
Joined: Mon Apr 23, 2012 4:28 pm
Location: Travelling through time and space...

Re: monitoring a service with a parameter

Postby gatorcb » Tue May 07, 2013 1:23 pm

The display name is LPD Service in services. Are you saying you can check the name and the running state? If so, how? Forgive me I'm not the nagios admin
gatorcb
 
Posts: 3
Joined: Tue May 07, 2013 11:52 am

Re: monitoring a service with a parameter

Postby sreinhardt » Tue May 07, 2013 1:44 pm

You most certainly can! How would depend on what you are using to check the windows client. Are you using a remote client, wmi or snmp? In most cases you would actually want the service name from the service properties not the display name.
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.
sreinhardt
-fno-stack-protector
 
Posts: 4366
Joined: Mon Nov 19, 2012 12:10 pm

Re: monitoring a service with a parameter

Postby gatorcb » Wed May 08, 2013 9:05 am

We are using snmp. The service name is LPDSVC. Any more specific information on how to monitor would be greatly appreciated
gatorcb
 
Posts: 3
Joined: Tue May 07, 2013 11:52 am

Re: monitoring a service with a parameter

Postby sreinhardt » Wed May 08, 2013 12:34 pm

According to some testing and many articles online. A Windows service can ONLY be seen via snmp if the service is presently running. With that being said you can walk the tree from svSvcName found in the mib C:\Windows\System32\lmmib2.mib. If the name is found, it is running, if not it is either disabled or not running presently. If it is running, there is additional data that you can query but as with before you cannot see if it is disabled or anything else if it is not running. I would highly suggest using WMI opposed to snmp for agentless checks against windows.
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.
sreinhardt
-fno-stack-protector
 
Posts: 4366
Joined: Mon Nov 19, 2012 12:10 pm


Return to Community Support

Who is online

Users browsing this forum: Google [Bot] and 25 guests