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

Re: Resizing LVM partition



Hi Tapani.

On Sunday, 29 March 2009 18:33:43 +0300,
Tapani Tarvainen wrote:

> > In the procedure that you mentioned, when erasing and creating the
> > larger partition the data that it maintainded will be lost
> 
> No it won't. The contents of the partition will stay in place,
> fdisk only changes the partition table. When the volume
> group is reawakened, it finds the data where it expects,
> only there will be unused space at the end of the partition,
> and pvresize will claim it.
> 
> At least that's how it works with normal disks, I don't
> know if your hardware RAID does something strange.

Interesting... I tried increasing the size of a LV on which a virtual
machine KVM is executed. Then with the operating system running, I
umount (although I have understood that it is not necessary) the
filesystem /space of the VM and I extended it so that it occupied all
the free space. Then I did resize of the extended partition and mounted
again /space, but still I continued seeing the old size. I tried doing
reboot and shutdown/start of the VM and I get the same result.

Peculiarly, starting a VM with a ISO of SystemRescueCD aiming to LV of
the VM, when mounting the resized partition yes I saw with the correct
size.

Booting once again the VM, I saw the partition with the correct size. I
do not believe that it has been something of filesystem cache of the VM
(because I suppose that after the boot it would have to display the
correct size). Perhaps some cache of hardware RAID on which is the LVM
filesystem?
 
Thanks for your reply.

Regards,
Daniel
-- 
Fingerprint: BFB3 08D6 B4D1 31B2 72B9  29CE 6696 BF1B 14E6 1D37
Powered by Debian GNU/Linux Squeeze - Linux user #188.598

Attachment: signature.asc
Description: Digital signature


Reply to: