From b9bea048c3d830946310cda5b9be337a30e42a04 Mon Sep 17 00:00:00 2001 From: Juan Ferrer Toribio Date: Fri, 29 Apr 2022 14:18:36 +0200 Subject: [PATCH] Include/ignore disks by UUID instead of VMDK filename --- debian/changelog | 2 +- vn-vmware.pl | 7 ++++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/debian/changelog b/debian/changelog index 568e677..4940c9c 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,4 +1,4 @@ -vn-vmware (1.1.31) stable; urgency=low +vn-vmware (1.1.32) stable; urgency=low * Initial Release. diff --git a/vn-vmware.pl b/vn-vmware.pl index 0879e7c..4e103c3 100755 --- a/vn-vmware.pl +++ b/vn-vmware.pl @@ -510,13 +510,14 @@ sub backup_machine() { $i++; my $disk_path = $device->backing->fileName; my $disk_file = basename($disk_path); + my $disk_uuid = $device->backing->uuid; - if (defined($backup_disks) && !($disk_file ~~ @$backup_disks)) { - log_message "$disk_path (Ignored)"; + if (defined($backup_disks) && !($disk_uuid ~~ @$backup_disks)) { + log_message "[$disk_uuid] $disk_path (Ignored)"; next; } - log_message $disk_path; + log_message "[$disk_uuid] $disk_path"; if ($disk_file ~~ @copied_devices) { $disk_file = "${i}_$disk_file";