On Mar 21, 2007, at 3:40 PM, Gregory K. Ruiz-Ade wrote:
4) if extended: "lvextend /dev/vgwhatever/lvol -L <new_size>"
Hmm... Might not be that simple.Actually, doing a sanity check, if you do the "I'll extend the Virtual Disk" instead of the "I'll add another Virtual Disk", you need to:
1) restart the VM after extending the vdisk 2) fdisk the LVM partition to enlarge it to consume the available space. 3) pvresize the partition (i.e., /dev/sda2) 4) lvextend whichever logical volume you want to extend 5) ext2online the logical volume device (i.e., /dev/vg00/lvol0) you could also: 2) fdisk to create a new partition in the empty space for LVM 3) pvcreate the new partition (/dev/sda3) 4) vgextend /dev/sda3 (add the new PV to the VG) 5) lvextend 6) ext2onlineDepending on a number of circumstances, when you modify the disk with fdisk, the kernel may get bitchy and request a reboot in order to get the new partition table correctly loaded. I hate this.
It's actually far simpler just to add a new virtual disk to the VM. In that case, it's literally:
1) stop the vm 2) add the new vdisk 3) restart the vm while your OS is happily running and doing its thing, 4) fdisk the new "drive" 5) pvcreate the single full-disk partition you created 6) vgextend onto the new PV 7) lvextend 8) ext2onlineThis still seems like too much of a song and dance for me. I long for ZFS, so I can say "YOU! use these drives. And make them reliable. Oh, here's one more."
Gregory -- Gregory K. Ruiz-Ade <[EMAIL PROTECTED]> OpenPGP Key ID: EAF4844B keyserver: pgpkeys.mit.edu
PGP.sig
Description: This is a digitally signed message part
-- [email protected] http://www.kernel-panic.org/cgi-bin/mailman/listinfo/kplug-list
