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

Re: [linux-lvm] how to determine minimum partition size based on PV size



On Thu, Jan 28, 2010 at 9:24 PM, Joe Harvell
<jharvell+lists lvm dogpad net> wrote:
> I need to reduce the size of an existing PV so that I can shrink the
> partition it resides on an reclaim the storage.  I have already shrunk
> the file systems and done an lvreduce.

before working on the PV, you also need to reduce the size of the
volume group the LV resides on.

> I have three questions:
>
> 1. Is the value of the '--setphysicalvolumesize' argument to the
> 'pvresize' command the size the physical volume (contents and metadata)
> will occupy on disk after the operation?  Or is it the specifying the
> new capacity of the PV to hold data?

In my understanding, the parameter specifies the total size of the PV.
The sum of PVs sizes (seen with pvdisplay) should be equal or larger
than the size of the VG residing on them.

> 2. How do I determine the minimum size I can specify to pvreduce and
> still have all of the original contents of the PV in the newly sized PV?

Multiply the number of allocated PEs to the size of a PE.

> 3. How do I determine the size the newly modified PV occupies on disk so
> that I can reduce the partition it lives on to its minimum size?

pvdisplay?


Sorry for the late reply, HTH.


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