Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

So I just extended the VG on my server. Basically, the local disk is 300GB. I initially created two partitions: sda1 is a primary partition, with ext4 assigned to /boot; sda2 is where 74G VG resides (vg is server hostname).

So I had an extra 225G left. I went ahead and created a third primary partition sda3, and after succesfuly creating a VG on sda3, I used lvextend to extend the size of my lv by 1GB.

So, here are the commands I ran after fdisk:

pvcreate /dev/sda3
vgextend hostname /dev/sda3
lvextend -L+1G /dev/hostname/home

For which I received the following output:

Extending logical volume home to 2.00 GiB
Logical volume home successfully resized

However, the prompt has been stuck on the last message now for several hours. My attempts to perform an lvscan / or lvdisplay fail with the following error:

/var/lock/lvm/V_hostname: flock failed: Interrupted system call
Can't get lock for hostname
Skipping volume group hostname

So my question is, do you think my system actually succesfully performed the resize? Am I safe to reboot? Or should I wait around a little longer? This is LVM2, so I was under the assumption that I could perform these operations live while the lv is actively mounted. I know this depends on type of filesystem you're using, but I figured I was good since I am on ext4.

share|improve this question

well, it should have gone OK (never had a problem resizing mounted Logical Volumes ...)

for some reason the system has not removed the LVM lock (is there a /var/lock/lvm/hostname file?)

you have not resized the FS yet so it should be ok to
1 remove lock

  rm /var/lock/lvm/hostname

2 reboot
3 check the status of the logical volume
4 resize the filesystem

good luck!

share|improve this answer

Save your lvm.conf

Change "locking_type = 3" with "locking_type = 0". Perform your pvs, lvs, vgs operation,

If everything looks good, then change back locking_type and reboot.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.