Converting Wizard based Router services to Templates
Posted: Wed Feb 03, 2021 2:57 pm
I am in the process of trying to setup hostgroup/service based templates for our Meraki based switches.
I've run the wizard against one switch and then tweaked the results into generic service checks that can be run against any Meraki switch. Pings and Port Up/Down went very smoothly. I'm having some issues wrapping my head around the bandwidth checks.
It looks like they are using the check_rrdtraf plugin to monitor a file at /var/lib/mrtg/routername_1.rrd
So 2 questions:
1) Is the "routername_1.rrd" file actually created by the wizard in the background? If so do I need to create this for every router? If so, can you talk about how to do this outside the wizard?
2) The actual service check from the wizard looks like this: /var/lib/mrtg/$ARG1$, with $ARG1$ being defined as routername_1.rrd
Assuming I can make a variable out of this, how can I format $ARG1$ to pass the hostname? Something like $HOSTNAME$_1.rrd feels right but I suspect I have the wrong syntax
Or is there a better way to make bandwidth charts for routers that fit in a template? Linux and Windows OS checks template just fine, but use a different plugin. Is there something similar for Routers?
I've run the wizard against one switch and then tweaked the results into generic service checks that can be run against any Meraki switch. Pings and Port Up/Down went very smoothly. I'm having some issues wrapping my head around the bandwidth checks.
It looks like they are using the check_rrdtraf plugin to monitor a file at /var/lib/mrtg/routername_1.rrd
So 2 questions:
1) Is the "routername_1.rrd" file actually created by the wizard in the background? If so do I need to create this for every router? If so, can you talk about how to do this outside the wizard?
2) The actual service check from the wizard looks like this: /var/lib/mrtg/$ARG1$, with $ARG1$ being defined as routername_1.rrd
Assuming I can make a variable out of this, how can I format $ARG1$ to pass the hostname? Something like $HOSTNAME$_1.rrd feels right but I suspect I have the wrong syntax
Or is there a better way to make bandwidth charts for routers that fit in a template? Linux and Windows OS checks template just fine, but use a different plugin. Is there something similar for Routers?