Re: Service not being monitored even though the poller test is successful

Jonathan Heard <[email protected]>
Newsgroups gmane.network.opennms.general
Message-ID <[email protected]>
Hi Dominic,

    In order for a service to be monitored, it must fall within the 
criteria set for the given poller 'package' - .e.g at the top of the 
poller-configuration.xml you should have something like:

    <package name="Default">
       <filter>(IPADDR != '0.0.0.0')</filter>

That <filter> tag is important because the poller will only apply to 
your host if it matches your filter criteria. This is certainly the 
first place I'd look.

In /var/log/opennms/poller.log you should be able to see messages like 
this one if the service is being excluded for not matching any <package> 
<filter> tags:
2018-01-08 15:00:11,814 WARN  [Poller:PollerEventProcessor-Thread] 
o.o.n.p.Poller: Active service Hawtio-8181 on 10.1.83.93 not configured 
for any package. Marking as Not Polled.

OpenNMS 16 is much older than I'm familiar with and possibly still uses 
the log4j rather than log4j2 but if you can find the relevant config 
file in /etc/opennms (e.g. log4j.properties or log4j2.xml) you can 
change the logging level for poller to 'DEBUG' and then get some more 
information from the above log.

e.g. A working poll for a node which has a 'CriticalProcess' monitor 
configured in the 'GLOBAL' package with a <filter> which doesn't exclude 
the it:
2018-01-22 15:52:12,510 DEBUG [Poller-Thread-9-of-30] 
o.o.n.p.p.PollableServiceConfig: Polling 
PollableService[location=Default, interface=PollableInterface 
[PollableNode [2]:10.1.0.1], svcName=CritialProcess] with TTL 30000 
using pkg GLOBAL

In my experience, whilst new pollers sometimes come up as 'Not 
Monitored' if OpenNMS hasn't been restarted, after a restart it always 
works so long as the config is correct.

Hope this helps
Jonathan


On 22/01/18 14:52, Brasted, Dominic wrote:
>
> Hello,
>
> I tried adding the SNMP port (161) to my poller-configuration.xml but 
> after a restart the Windows service is still showing as “not monitored”.
>
> Can anyone suggest what else might be the problem?
>
> Thanks.
>
> Regards, Dominic
>
> *From:* Brasted, Dominic [mailto:[email protected]]
> *Sent:* Tuesday, December 12, 2017 2:03 PM
> *To:* General OpenNMS Discussion <[email protected]>
> *Subject:* [opennms-discuss] Service not being monitored even though 
> the poller test is successful
>
> Hello,
>
> IÂ’m having trouble getting OpenNMS to monitor a Windows service. IÂ’ve 
> added it to /opt/opennms/etc/default-foreign-source.xml via the GUI 
> and to my poller-configuration.xml (and restarted the opennms 
> service), and when I do a poller-test it comes back successful. 
> OpenNMS detects the service but shows it as not monitored.
>
> I would appreciate your assistance. WeÂ’re running OpenNMS 16.0.3.
>
> Here are the relevant portions of my config files:
>
> *default-foreign-source.xml*
>
>       <detector name="SolarWinds Storage Manager Agent Service" 
> class="org.opennms.netmgt.provision.detector.snmp.Win32ServiceDetector">
>
>          <parameter key="win32ServiceName" value="SolarWinds Storage 
> Manager Agent Service"/>
>
>          <parameter key="retries" value="2"/>
>
>          <parameter key="timeout" value="5000"/>
>
>       </detector>
>
> *poller-configuration.xml*
>
>       <service name="SolarWinds-Storage-Manager-Agent" 
> interval="300000" user-defined="false" status="on">
>
>          <parameter key="retry" value="2"/>
>
>          <parameter key="timeout" value="5000"/>
>
>          <parameter key="service-name" value="SolarWinds Storage 
> Manager Agent Service"/>
>
>       </service>
>
>    <monitor service="SolarWinds-Storage-Manager-Agent" 
> class-name="org.opennms.netmgt.poller.monitors.Win32ServiceMonitor"/>
>
> *Output from poller-test*
>
> Checking service SolarWinds-Storage-Manager-Agent on IP xxx.xxx.xxx.xxx
>
> Package: example1
>
> Monitor: org.opennms.netmgt.poller.monitors.Win32ServiceMonitor
>
> Parameter service-name : SolarWinds Storage Manager Agent Service
>
> Parameter retry : 2
>
> Parameter timeout : 5000
>
> Available ? true (status Up[1])
>
> Response time: 80.951263
>
> Thanks.
>
> Regards, Dominic
>
>
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>
>
> _______________________________________________
> Please read the OpenNMS Mailing List FAQ:
> http://www.opennms.org/index.php/Mailing_List_FAQ
>
> opennms-discuss mailing list
>
> To *unsubscribe* or change your subscription options, see the bottom of this page:
> https://lists.sourceforge.net/lists/listinfo/opennms-discuss

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot

_______________________________________________
Please read the OpenNMS Mailing List FAQ:
http://www.opennms.org/index.php/Mailing_List_FAQ

opennms-discuss mailing list

To *unsubscribe* or change your subscription options, see the bottom of this page:
https://lists.sourceforge.net/lists/listinfo/opennms-discuss
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.