mirror of
https://github.com/monitoring-plugins/monitoring-plugins.git
synced 2026-05-28 04:35:40 -04:00
check_dhcp: fix tests interface detection
This commit is contained in:
parent
9090beb058
commit
08d554ada1
1 changed files with 1 additions and 1 deletions
|
|
@ -36,7 +36,7 @@ my $hostname_invalid = getTestParameter( "NP_HOSTNAME_INVALID",
|
|||
|
||||
# try to determince interface
|
||||
my $interface = '';
|
||||
if(`ifconfig -a 2>/dev/null` =~ m/^(e(m|th)\d+)/mx and $1 ne 'eth0') {
|
||||
if(`ifconfig -a 2>/dev/null` =~ m/^(e\w*\d+)/mx and $1 ne 'eth0') {
|
||||
$interface = ' -i '.$1;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue