Why are my LVM volumes missing after creating a partition table?
Issue
- Why are my LVM volumes missing after creating a partition table?
- My LVM Physical Volumes (PVs), Volume Groups (VGs), and Logical Volumes (LVs) cannot be found.
- One physical volume
/dev/sdXis listed as "unknown device" even though it appears in/proc/partions:
# lvs -a -o +devices
Couldn't find device with uuid aaaaaa-bbbb-cccc-dddd-eeee-ffff-gggggg.
LV VG Attr LSize Origin Snap% Move Log Copy% Convert Devices
lv_root localvg00 -wi-ao 4.00G /dev/sda2(512)
lv_data localvg00 -wi-ao 40.00G unknown device(0) <----
# grep sdX /proc/partitions
8 16 49283072 sdX
8 17 49283040 sdX1
- I get the following error when trying to restore LVM metadata on a Physical Volume:
Can't open /dev/sdX exclusively. Mounted filesystem?
Environment
- Red Hat Enterprise Linux
- LVM2 Logical Volume Manager
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.
Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.
