From 4c5a6a241979e1ec49ab610e2766d0f7386ec5d9 Mon Sep 17 00:00:00 2001 From: Thomas Lamprecht Date: Tue, 26 Feb 2019 08:20:37 +0100 Subject: [PATCH] ivmshmem: comment deletion of shm on VM stop in code Signed-off-by: Thomas Lamprecht --- PVE/QemuServer.pm | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/PVE/QemuServer.pm b/PVE/QemuServer.pm index 1dc3ca7f..4e9db0c8 100644 --- a/PVE/QemuServer.pm +++ b/PVE/QemuServer.pm @@ -5506,6 +5506,10 @@ sub vm_stop_cleanup { if ($conf->{ivshmem}) { my $ivshmem = PVE::JSONSchema::parse_property_string($ivshmem_fmt, $conf->{ivshmem}); + # just delete it for now, VMs which have this already open do not + # are affected, but new VMs will get a separated one. If this + # becomes an issue we either add some sort of ref-counting or just + # add a "don't delete on stop" flag to the ivshmem format. unlink '/dev/shm/pve-shm-' . ($ivshmem->{name} // $vmid); }