# 17 ------------------------------------------------------------------------ # # Data to graph: Check tcp port access # # Service type: check-tcp-port # # Nagios plugin: check_tcp # # Nagios output: TCP OK - 0.061 second response time on port 22 # # Use perfdata: time=0.060777s;0.000000;0.000000;0.000000;10.000000 # # --------------------------------------------------------------------------- # /output:TCP.*?on port (\d+)\s*perfdata:time=(\d+\.\d+).*(\d+\.\d+)\D*(\d+\.\d+)\D*(\d+\.\d+)\D*(\d+\.\d+)/ and push @s, [ "tcp_$1", [ 'connect_time', GAUGE, $2 ], [ 'warning_time', GAUGE, $3 ], [ 'critical_time', GAUGE, $4 ], [ 'socket_timeout', GAUGE, $6 ], ];