[Libguestfs] [PATCH <= 1.32] appliance: Disable lvmetad.

Richard W.M. Jones rjones at redhat.com
Mon Aug 8 15:00:46 UTC 2016


lvmetad only works if the /run/lvm directory is created.  It is
normally created by systemd-tmpfiles, but prior to libguestfs 1.34 we
didn't invoke systemd-tmpfiles to create directories under /run (fixed
in upstream commit a6330e9d3af0f5286f1d53d909fd868387b67f69).

If for some reason lvmetad does start, then LVM filtering will be
broken (fixed in upstream commit 5ce19cec4cd6d819a9405d1a470dc128fdc0e4d7).

This means that our appliance is fragile.  lvmetad normally won't
start up even though the command is included in the init script.  If
it does start up for some reason, then it will break other things.

It is therefore better to disable lvmetad entirely.

Note this patch is only for libguestfs <= 1.32.  This is fixed
properly in libguestfs >= 1.34.
---
 appliance/init | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/appliance/init b/appliance/init
index 4ed7927..311a0d4 100755
--- a/appliance/init
+++ b/appliance/init
@@ -124,7 +124,7 @@ mdadm -As --auto=yes --run
 
 # Scan for LVM.
 modprobe dm_mod ||:
-lvmetad ||:
+#lvmetad ||:
 
 lvm vgchange -aay --sysinit
 
-- 
2.7.4




More information about the Libguestfs mailing list