[pve-devel] [PATCH container 1/1] sync_container_namespace: skip virtual filesystems

Stoiko Ivanov s.ivanov at proxmox.com
Thu Sep 17 21:17:01 CEST 2020


skip additional virtual filesystems.

the list is taken from a running debian container's /proc/mounts

Signed-off-by: Stoiko Ivanov <s.ivanov at proxmox.com>
---
 src/PVE/LXC.pm | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/PVE/LXC.pm b/src/PVE/LXC.pm
index b3e3581..b67d872 100644
--- a/src/PVE/LXC.pm
+++ b/src/PVE/LXC.pm
@@ -1107,7 +1107,7 @@ my $do_syncfs = sub {
     my $mounts = PVE::ProcFSTools::parse_mounts($mountdata);
     foreach my $mp (@$mounts) {
 	my ($what, $dir, $fs) = @$mp;
-	next if $fs eq 'fuse.lxcfs';
+	next if $fs =~ /cgroup|devtmpfs|devpts|fuse.lxcfs|mqueue|fusectl|proc|sysfs|tmpfs/;
 	eval { PVE::Tools::sync_mountpoint($dir); };
 	warn $@ if $@;
     }
-- 
2.20.1






More information about the pve-devel mailing list