Description of problem:
With recent lvm2 versions, like the one updated in RHEL 6.6, the lvm-set-filter API breaks (test test-lvm-filtering.sh fails).
This happens because in libguestfs < 1.26.9 the lvm-set-filter API manually edits, in a copy of lvm.conf, the uncommented 'filter =' line with the devices to be handled by lvm; recent lvm2 versions do not have any uncommented filter line anymore, and thus the previous libguestfs way breaks.
Further details and upstream fixes are in the following thread:
Steps to Reproduce:
1. Use lvm-set-filter to set some filter
2. Query the vg's using the vgs API
All the vg's.
Only the vg's matching the set filter.
This has been fixed using three commits (and a cleanup/fixup later one):
The third one brings an own version of the lvm lens of Augeas; most probably we can have the changes directly in Augeas itself.
Verify with libguestfs-1.20.11-12.el6
1. add images into guestfish
$ guestfish -a test1.img -a RHEL-Server-7.0-64-hvm.raw
2. list the LVM volume groups
3. set filter and list vgs
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.
For information on the advisory, and where to find the updated
files, follow the link below.
If the solution does not work for you, open a new bug report.