In computer storage, Logical Volume Management or LVM provides a method of allocating space on mass-storage devices that is more flexible than conventional partitioning schemes.
Questions tagged [lvm]
1553 questions
197
votes
6 answers
LVM dangers and caveats
I have recently started using LVM on some servers for hard drives larger than 1 TB. They're useful, expandable and quite easy to install. However, I could not find any data about the dangers and caveats of LVM.
What are the downsides of using LVM?
Adam Matan
- 14,084
88
votes
4 answers
How to find the physical volume(s) that hold a logical volume in LVM
I have a volume group (VG) that contains two physical volumes (PV).
Several logical volumes (LV) in the VG are likely to use extents on both PVs.
Is there a way to tell which LVs occupy space on which PVs?
Paul
- 2,068
66
votes
3 answers
Is it possible to on-line shrink a EXT4 volume with LVM?
Today I tried this on my machine with OpenSUSE 12.3 (kernel 3.7):
# resize2fs /dev/mapper/system-srv 2G
resize2fs 1.42.6 (21-Sep-2012)
Filesystem at /dev/mapper/system-srv is mounted on /srv; on-line resizing required
resize2fs: On-line shrinking…
Alicia
- 815
59
votes
6 answers
What is better LVM on RAID or RAID on LVM?
I currently have LVM on software RAID, but I'd like to ask you what you think it is better solution, maybe some pros and cons?
Edit: It is about software raid on lvm or lvm on software raid. I know than hardware raid is better if we are thinking…
Ency
- 1,271
39
votes
6 answers
How to display used devices/free space when using LVM?
I have following situation:
=$ LC_ALL=C df -hP | column -t
Filesystem Size Used Avail Use% Mounted on
/dev/mapper/vg0-rootlv 19G 854M 17G 5% /
/dev/mapper/vg0-homelv 19G 343M 18G 2% /home
/dev/mapper/vg0-optlv …
user13185
37
votes
4 answers
Readahead Settings for LVM, Device-Mapper, Software Raid and Block Devices - what wins?
I've been trying to find a straight answer on this one, and it has proved elusive. This question and its answer is close, but does not really give me the specifics I would like. Let's start with what I think I know.
If you have a standard block…
Adam C
- 5,262
36
votes
3 answers
Removing vg and lv after physical drive has been removed
We had a disk fail in a server and replaced it before removing the drive from LVM.
The server has 4 physical drives (PV's), each with it's own volume group (VG). Each VG has 2 or more logical volumes (LV's.) Now LVM is complaining about the…
Dokbua
- 1,082
36
votes
6 answers
LVM Performance overhead?
I would be thankfull if someone who understands how LVM works, could tell me a rough estimate, how much slower using LVM (with a Software RAID1) will be.
(What I do not want to know how much slower LVM will be if the LVM Volume is currently in…
jens
- 407
36
votes
2 answers
LV Status: Not available. How to make it available?
I connect an iSCSI target, create a Physical Volume and Volume Group on it.
Then I create an LV, and
mkfs.ext3 /dev/vg00/vm
and all that works great.
Then I disconnect the target
iscsiadm -m node -T iqn.2004-04.com.qnap:ts-509:iscsi.linux01.ba4731…
Sandra
- 10,711
- 41
- 120
- 173
35
votes
4 answers
LVM snapshots vs. file system snapshots
As far as I know, LVM makes it possible to take snapshots of a volume. There are also a number of file systems (ZFS, Btrfs, reiserfs, ...) which supports snapshots.
However, I've never understood the difference between LVM snapshots and file system…
nip3o
- 507
30
votes
7 answers
How to resize root LVM partition in Fedora without LiveCD or Rebooting
I have a virtual machine that recently had its disk image increased from 20GB to 50GB, and fdisk -l verifies that the VM can see this new size. Now I need to resize my root LVM partition to fill the extra 30GB.
I've found several articles about…
Cerin
- 3,910
- 21
- 66
- 85
30
votes
1 answer
When using software RAID and LVM on Linux, which IO scheduler and readahead settings are honored?
In the case of multiple layers (physical drives -> md -> dm -> lvm), how do the schedulers, readahead settings, and other disk settings interact?
Imagine you have several disks (/dev/sda - /dev/sdd) all part of a software RAID device (/dev/md0)…
andrew311
- 401
30
votes
14 answers
Can't remove open logical volume
When I try to remove a logical volume I get the message
#lvremove /dev/my-volumes/volume-1
Can't remove open logical volume "volume-1"
#lvchange -an -v /dev/my-volumes/volume-1
Using logical volume(s) on command line
/dev/dm-1: read failed after…
Everett Toews
- 693
29
votes
7 answers
Does LVM need a partition table?
It appears that I am able to successfully do a pvcreate on top of a raw block device, without ever taking the step of creating a partition table. I am then able to create a volume group, logical volume, and finally a filesystem, mount it, and test…
cat pants
- 2,363
26
votes
5 answers
Is this how LVM snapshots work?
I'm trying to figure out how LVM snapshots work so I can implement it on my fileserver but I'm having difficulty finding anything on google that explains how it works, instead of how to use it for a base backup system.
From what I've read I think it…
Malfist
- 837