Bug 986954 - LVM2 commands in F19 started to report "No device found for PV ..." if global_filter is used
LVM2 commands in F19 started to report "No device found for PV ..." if global...
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: lvm2 (Show other bugs)
19
All Linux
high Severity medium
: ---
: ---
Assigned To: Petr Rockai
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2013-07-22 09:45 EDT by Peter Rajnoha
Modified: 2013-07-28 20:25 EDT (History)
11 users (show)

See Also:
Fixed In Version: lvm2-2.02.98-10.fc19
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-07-28 20:25:47 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Peter Rajnoha 2013-07-22 09:45:21 EDT
Opening this BZ to not forget to backport the patch for F19 and for anybody else who could have hit this problem already...

Fedora 19 started using lvmetad together with LV autoactivation by default. In this setup, the volumes are activated once all the PVs making up the VG are in place. This is accomplished by running pvscan --cache --major ... --minor ... within udev rules that notify lvmetad about new device appeareance and stored this information together with scanned LVM metadata for that device.

When running pvscan --cache, the devices/filter is not applied and lvmetad records all the incoming PVs without any filtering. However, there are cases in which we need to globally filter out devices from being scanned and so not updating lvmetad about it (e.g. in case we have disks for virtual machines which have VGs/LVs defined inside that we do not want to show in host machine). For this purpose, there's the devices/global_filter setting.

The pvscan --cache --major --minor should respect the devices/global_filter setting, otherwise, we end up with:

  - LVs activated on the host side that were not supposed to be seen at all
  - LVM commands giving "No device found for PV <PV_UUID>" message as lvmetad provides the info about the PV, but this one is ignored on the client (lvm command) side

The problem here is that pvscan --cache --major ... --minor ... did not respect the devices/global_filter setting. This patch fixes it:

https://git.fedorahosted.org/cgit/lvm2.git/commit/?id=3fdb45d0402ac9b404f4277d7954043ea257f019
Comment 1 Peter Rajnoha 2013-07-22 09:47:47 EDT
(In reply to Peter Rajnoha from comment #0)
> The pvscan --cache --major --minor should respect the devices/global_filter
> setting, otherwise, we end up with:
> 
>   - LVs activated on the host side that were not supposed  to be seen at all
>   - LVM commands giving "No device found for PV <PV_UUID>" message as
> lvmetad provides the info about the PV, but this one is ignored on the
> client (lvm command) side

 - also VGs/LVs activated, but not visible to vgs/lvs command
Comment 2 Fedora Update System 2013-07-26 08:21:17 EDT
lvm2-2.02.98-10.fc19 has been submitted as an update for Fedora 19.
https://admin.fedoraproject.org/updates/lvm2-2.02.98-10.fc19
Comment 3 Fedora Update System 2013-07-26 18:59:49 EDT
Package lvm2-2.02.98-10.fc19:
* should fix your issue,
* was pushed to the Fedora 19 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing lvm2-2.02.98-10.fc19'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2013-13665/lvm2-2.02.98-10.fc19
then log in and leave karma (feedback).
Comment 4 Fedora Update System 2013-07-28 20:25:47 EDT
lvm2-2.02.98-10.fc19 has been pushed to the Fedora 19 stable repository.  If problems still persist, please make note of it in this bug report.

Note You need to log in before you can comment on or make changes to this bug.