Skip to content

Conversation

@olliewalsh
Copy link

This:
./check_netint.pl -H 172.16.203.172 -C public -n "eth\d+|em\d+" -f -q -k -y -M -B -m -P "DATA: cache_descr_ids=2 cache_descr_names=eth0 cache_descr_time=1383918585 'eth0_in_octet'=3326101411 'eth0_out_octet'=933507763 'eth0_in_octet.1383849652'=2790378964 'eth0_out_octet.1383849652'=533846849 ptime=1383918385" -T 1383918585 -e -z --nagios_longoutput

Outputs the following:
eth0:UP (0.0Mbps/0.0Mbps/0.0/0.0/0.0/0.0) (1 UP): OK | 'eth0_in_prct'=0% 'eth0_out_prct'=0% 'eth0_in_error'=0 'eth0_out_error'=0 'eth0_in_discard'=0 'eth0_out_discard'=0
DATA: cache_descr_ids=2 cache_descr_names=eth0 cache_descr_time=1383918585 'eth0_in_octet'=3326494996 'eth0_out_octet'=933967457 'eth0_in_octet.1383918385'=3326101411 'eth0_out_octet.1383918385'=933507763 ptime=1383918621

... which is valid PERFDATA. Without this option the -P option produces invalid PERFDATA and graphing tools reject it (e.g php4nagios).

@willixix
Copy link
Owner

You're welcome to use this code for your own systems but I will not add this to plugin base cade because LONGSERVICE is something else and not designed for storing data variables. Its even worth for it than PERFDATA.

And as far as support for graphing programs, you should use custom templates to specify exactly what perfdata to process. For PnP look at my github under graphing_templates/pnp4nagios and you'll find a template and config for this plugin and custom modified processdata perl script that adds new options for PNP in part to handle check_netint

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants