added a message in 'libvirt.pm' if the MAC address of a VM is not found

This commit is contained in:
Jordi Sanfeliu 2016-06-15 10:51:31 +02:00
parent 2e0d232016
commit 4866ad410c
1 changed files with 5 additions and 0 deletions

View File

@ -252,6 +252,11 @@ sub libvirt_update {
}
close(IN);
}
if(!$vnet) {
logger("$myself: invalid MAC address '$vn' in '$vm'.");
next;
}
if(open(IN, "$libvirt->{cmd} domifstat $vm $vnet |")) {
my $r = 0;
my $w = 0;