For the benefit of anyone on the list who doesn't use JIRA... and also so that others who support (want/need) this feature can comment.https://jira.observium.org/browse/OBS-2925Attached patch defines OBS_SNMP_SKIP flag and uses snmp_skip device attribute, similar to OBS_PING_SKIP and ping_skip, in order to have hosts that are ping only.
Ping only hosts can still have the Observium Unix Agent installed (tested), and other poller modules such as IPMI enabled (untested).
Tested:
- Add/remove/rename ping only hosts via CLI
- Add/remove ping only hosts via webUI
- View/interact ping only hosts via webUI - SNMP specific features/menus etc are hidden while skip SNMP is enabled
- Alerting - device_status equals 0 && device_status_type equals ping - will trigger alerts for host down/recovery events
- Shifting a previously SNMP contactable host to ping only by ticking skip SNMP box - old SNMP graphs/etc are maintained and remain available - remove skip SNMP box and SNMP polling begins again
Things I know kind of don't work right now:
- Location override - poller/discovery doesn't seem to perform geocoding and whatever else is happening there
Things that could be improved:
- Unix Agent poller module etc is enabled by default for all hosts, for ping only hosts, perhaps it should be disabled by default? Will improve performance by reducing the number of processes that hang while the 10s default connect timeout happens.
Totally untested:
- Use of autodiscovery SNMP skip - should work in theory, unsure if those parts of the patch should actually be used though. Some people out there may actually want to add anything that does respond to ping and can be found thru adjacency and routing protocol info etc??
Patch generated from recent trunk, touches files as below,
[root@desktop observium]# diff -r -u observium-trunk root | grep -v ^Only > ping_only_hosts.diff
[root@desktop observium]# cd root
[root@desktop root]# svn status
M add_device.php
M html/pages/addhost.inc.php
M html/pages/device/edit/device.inc.php
M html/pages/device/edit.inc.php
M html/pages/device/graphs.inc.php
M html/pages/device/perf.inc.php
M includes/config-variables.inc.php
M includes/defaults.inc.php
M includes/definitions.inc.php
M includes/discovery/functions.inc.php
M includes/functions.inc.php
M includes/polling/functions.inc.php
M poller.php
M rename_device.php
[root@desktop root]# svn info | grep ^Revision
Revision: 9704
[root@desktop root]#
[root@desktop observium]# mv ping_only_hosts.diff ping_only_hosts_r9704.diff-Colin
Email: cstubbs @ gmail . com_______________________________________________ observium mailing list observium@observium.org http://postman.memetic.org/cgi-bin/mailman/listinfo/observium