-   Linux - Newbie (
-   -   how can increase my physical volume group space in linux (

ilu_nishant 09-10-2009 10:19 AM

how can increase my physical volume group space in linux
I have created a physical volume group with partitions /dev/sda{5,6}

#pvcreate /dev/sda{5,6}

Then I created volume group named VolGrp1 from this physical group

#vgcreate VolGrp1 /dev/sda{5,6}

Then I created a Logical Volm grp from this .

#lvcreate -L 50M -n LogGrp1 VolGrp1
#mke2fs -f /dev/VolGrp1/LogGrp1
#mount /dev/VolGrp1/LogGrp1 /data_LVM

Now I want to add 1 more partition to my physical Volume Grp i.e. /dev/sda7. How can I add this /dev/sda7 to my existing Phy. Volm Grp.

so that after adding this I can increase the space to my VolGrp1 by using
#vgextend VolGrp1 /dev/sda7 command ..Plz tell how can I achieve this without any data loss...

Thanks in advance..

rayfordj 09-10-2009 12:30 PM


pvcreate /dev/sda7
vgextend VolGrp1 /dev/sda7

EDIT: any data on /dev/sda7 will be lost.


karlatLQ 09-10-2009 01:19 PM

Have something similar, trying to add space the LV but instead of command line am using the LVM tool with FC11. See LV post. Agree with rayfordj that you will lose the data to the partition that you are adding. If you are concerned about data loss to the partitions that are already part of the LV, then you should do what I tell people to do all the time. Back up data. At least back up important data.

ilu_nishant 09-12-2009 02:41 PM

I'm able to add a new partition "/dev/sda7" to my existing physical volume and hence extended my Volume Group space too succesfully.

Yes , all data /dev/sda7 got lost while adding this new partition /dev/sda7 to physical volume but the data present in my existing Volume Group "VolGrp1" remains intact after extending space of Volume Group.

Issue resolved .. Thanks for the support.:)

All times are GMT -5. The time now is 09:27 PM.