Re: shrink pv without pvresize (FC3 LVM)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Dec 10, 2004 at 05:55:09PM -0500, Ilya Goldin wrote:
> # pvresize
 
> Is there a workaround (short of writing pvresize)?
 
Yes - vgcfgbackup, edit backup file, vgcfgrestore.

The field you need to edit to change the size is pe_count
according to:

  pe_start + pe_count * extent_size <= dev_size

i.e.
  pe_count <= (dev_size - pe_start) / extent_size

You can find out the current device size with:
  pvs -o +dev_size --units s

[The units used in the file are sectors of 512 bytes]

Only change pe_count for the PV you're resizing and nothing else!

Alasdair
-- 
agk@redhat.com

_______________________________________________
linux-lvm mailing list
linux-lvm@redhat.com
https://www.redhat.com/mailman/listinfo/linux-lvm
read the LVM HOW-TO at http://tldp.org/HOWTO/LVM-HOWTO/

[Index of Archives]     [Gluster Users]     [Kernel Development]     [Linux Clusters]     [Device Mapper]     [Security]     [Bugtraq]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]

  Powered by Linux