Bu Blogda Ara

18 Nisan 2011 Pazartesi

How to extend a Virtual Box Image Hard Disk Size

1-) Use clonezilla latest.iso and boot from Virtual Machine the iso.

2-) Copy the source disk to target disk with Expert mode and k1 mode selected which is for scaling up the existing virtual disk to target virtual disk.

3-) When finished open the virtual machine with a latest gparted.iso image.

4-) Enter the commmand line mode and pvscan the virtual hard disk and Note your virtual harddisk path such as /dev/sda2

5-) sudo pvresize /dev/sda2 This is done for resizing the outer LVM2 type Virtual Disk partition.

6-) lvscan to discover internally mapped virtual ext3 or ext2 linux partitions such as /dev/mapper/virtual-disk-name

7-) sudo lvresize -L /dev/mapper/virtual-disk-name This will extend your inner mapped linux partition.

8-) resize2fs /dev/mapper/virtual-disk-name This will resize the filesystem.