Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I need to Extend the LVM on one server. This is the df -h result.

Filesystem            Size  Used Avail Use% Mounted on
/dev/cciss/c0d0p2      58G   26G   29G  48% /
/dev/mapper/VolGroup00-LogVol00
                      476G   86G  366G  19% /u001/app/oracle
/dev/cciss/c0d0p1     487M   17M  445M   4% /boot
tmpfs                  16G  730M   16G   5% /dev/shm

And I need to extend /dev/mapper/VolGroup00-LogVol00 from 475G to 700G. I have enough space to do this.

Any suggestions? Please mention all steps and prerequisites

Further Details

Before I go and apply this on actual server. I first plan to do this on a virtual machine. So I installed 5.6 on VirtualBox and assigned 25GB for installation.

df -h result:

DF

And when I used the command

lvextend -L +500M /dev/mapper/VolGroup00-LogVoll00

its reply was “insufficient space”.

LV

Although there is uninitialized space ready to be used.

VGDISPLAY

Seems it didn't work. Please advice whats wrong here.

Output of vgs and pvs commands

enter image description here

share|improve this question
    
There is not "uninitialized space ready to be used". Free PE / Size 0 / 0. –  Mikel Dec 12 '12 at 23:43
add comment

2 Answers

up vote 4 down vote accepted

First of all, check that you really have already space on your VG. In your example "Free PE" is 0, so you cannot extend any LV in it. If you do not have space on that VG, please add create new PEs with command pvcreate and add them to VG with command vgextend. Once you have enough space, just estend your LV with command lvextend and then resize your file system.

share|improve this answer
    
Ok dear. As there was no Free space so by using pvcreate i created Physical drive and then vgextend VolGroup00 /dev/PathToPart and finally I used lvextend /dev/VolumeGroup00/Logvol -l 100%VG and then used resize2fs to update the Logical Volume. –  OmiPenguin Dec 15 '12 at 9:55
add comment

first make sure required size available or not on your physical volume using :

$ vgs

then try below to extend:

$ lvextend –L +500M /dev/mapper/VolGroup00-LogVol00
$ resize2fs /dev/mapper/VolGroup00-LogVol00
share|improve this answer
    
Dear I have added the details in question under Further Details section Thanks –  OmiPenguin Dec 12 '12 at 13:27
1  
Hi, it's seems your volume group already used , you need to extend your pv and vg first then you can extend your lv –  Rahul Patil Dec 12 '12 at 13:39
add comment

Your Answer

 
discard

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.