Use fping6 instead of fping for hosts with udp6/tcp6 SNMP transports

This commit is contained in:
Nils Steinger
2015-09-22 02:25:35 +02:00
parent e5018c80bc
commit ac001191dc
3 changed files with 30 additions and 7 deletions

View File

@@ -154,7 +154,9 @@ function poll_device($device, $options) {
echo "Created directory : $host_rrd\n";
}
$ping_response = isPingable($device['hostname'], $device['device_id']);
$address_family = snmpTransportToAddressFamily($device['transport']);
$ping_response = isPingable($device['hostname'], $address_family, $device['device_id']);
$device_perf = $ping_response['db'];
$device_perf['device_id'] = $device['device_id'];