Skip to main content

Hi everybody, 

I’m new in Centreon’s world (and to the world of monitoring).

In my Centreon, I’ve many hosts where I monitor processes or services (Windows). 

What is the best practice for checking processes?

Currently, I have 1 check per service, like this:

/usr/lib/xxx/xxx//centreon_windows_snmp.pl --plugin=os::windows::snmp::plugin --mode=service --hostname=1.2.3.4 --snmp-version='2c' --snmp-community='public'  --service='service_name1' --warning= --critical= --state='' --regexp

             Result : OK: Service 'service1' state is 'active' einstalled state: 'installed']

/usr/lib/xxx/xxx//centreon_windows_snmp.pl --plugin=os::windows::snmp::plugin --mode=service --hostname=1.2.3.4 --snmp-version='2c' --snmp-community='public'  --service='service2' --warning= --critical= --state='' --regexp
              Result : OK: Service 'service2' state is 'active' installed state: 'installed']


etc…

I’ve tried to use just one command, with this syntaxe : 

​​​​​​​/usr/lib/xxx/xxx//centreon_windows_snmp.pl --plugin=os::windows::snmp::plugin --mode=service --hostname=1.2.3.4 --snmp-version='2c' --snmp-community='public'  --service='”service_name2””service_name3””service_nameXXXX”' --warning= --critical= --state='' --regexp

But the result is: OK: | 'services.total.count'=0;;;0; 'services.active.count'=0;;;0;.
And if I stop a service, Centreon says 'Everything is OK'.


So, how do we really go about it? 

Thanks in advance! 
 

Greetings,

The result is OK because you don’t have any thresold set for what will trigger the warning,critical or unknown status.

You may try something like this for example if you were to monitor the centengine process on a Centreon poller.

/usr/lib/centreon/plugins//centreon_linux_snmp.pl --plugin=os::linux::snmp::plugin --mode=processcount --hostname=x.x.x.x --snmp-version='2c' --snmp-community='public'  --process-name='centengine' --process-path='/usr/sbin/' --process-args='' --regexp-name --regexp-path --regexp-args --warning='' --critical='1:1' 

For more on the matter, I would recommend this topic:
 

 


Reply