In weathermap link utilization is working fine.
I want to monitor host and link status. For example, if host is up = green, down = red, error = orange. same for links also. After hours of googling came up with following for host status.
But it always shows green even libre says host is down. Can anybody guide what might be wrong ? Also like to know how to monitor port status in Weathermap.
Old post, but this was bugging me recently and I ended up doing the below. I tried fping and even tried altering the datasource plugin to understand it better but never got any luck.
Below I have white for normal, red if no ping stats. Added the actual number (latency ms) in a label for testing below it as an option too:
Define an updown scale, then use it along with a target that directly references the ping-perf.rrd of the host in question. When the host is down, the RRD ends up with NaN and that translates to 0 when extracted and displayed:
SCALE updown 0 0 255 0 0
SCALE updown 0 10000 255 255 255
NODE BLAH-SW01
LABEL BLAH-SW01
INFOURL /device/device=63/
OVERLIBGRAPH /graph.php?height=100&width=512&device=63&type=device_bits&legend=no
ICON 80 80 images/WorkgroupSwitch.png
LABELOFFSET 0 25
POSITION 178 521
USESCALE updown in
TARGET gauge:./BLAH-SW01/ping-perf.rrd:ping:-
# if you want the number for debugging/validation:
NODE BLAH-SW01-LATENCY
LABEL {node:this:inpercent:%k}
POSITION 178 570
USESCALE updown in
TARGET gauge:./BLAH-SW01/ping-perf.rrd:ping:-
If you wanted to graduate the latency values in to a colour scale, you could do that too.
Excellent! Thank you for sharing. This is what Iāve been looking for.
I had it working and then I updated to the latest build and it seems the logic for getting the RRD path changed somewhere between the old version I was running and the most current.
Is this configuration you shared still working on the latest build?
Post update all the nodes I had setup using your example return the following now
ā¦had no valid data, according to WeatherMapDataSource_rrd
EDIT:
Upon further investigation it appears it may be due to the fact that Iām running rrdcached
After playing around with it some more I wasnāt convinced it was the right fit for me, rrdcache seemed to throw a wrench into this method. I wanted to leverage the LibrenmsAPI for device status so I ended up writing a datasource plugin that does just that. I think itās more true to reflect exactly what you would see in the librenms dashboard availability map regardless of what your RRD environment looks like.
I made a pull request on the plugin , hereās the file if anyone is interested.
Thank you for this code.
I was looking for something like this to easily color code the map.
I had originally assumed that that was what the weathermap would do, until everything stayed the same color regardless of connection.