[pve-devel] [PATCH storage 1/2] esxi: fix #5587: add support for older version of vmx storage filepaths

Daniel Kral d.kral at proxmox.com
Wed Aug 21 15:57:47 CEST 2024


Allow the ESXi storage disk entry property "fileName" to be flatcased
("filename") in addition to being camelcased ("fileName"). This adds
compatibility with older ESXi .vmx configuration files.

Signed-off-by: Daniel Kral <d.kral at proxmox.com>
---
 src/PVE/Storage/ESXiPlugin.pm | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/PVE/Storage/ESXiPlugin.pm b/src/PVE/Storage/ESXiPlugin.pm
index a35693d..e99b54c 100644
--- a/src/PVE/Storage/ESXiPlugin.pm
+++ b/src/PVE/Storage/ESXiPlugin.pm
@@ -754,7 +754,7 @@ sub manifest { $_[0]->{'pve.manifest'} }
 # (Also used for the fileName config key...)
 sub is_disk_entry : prototype($) {
     my ($id) = @_;
-    if ($id =~ /^(scsi|ide|sata|nvme)(\d+:\d+)(:?\.fileName)?$/) {
+    if ($id =~ /^(scsi|ide|sata|nvme)(\d+:\d+)(:?\.file[nN]ame)?$/) {
 	return ($1, $2);
     }
     return;
-- 
2.39.2





More information about the pve-devel mailing list