HOWTO:XENMOdifyStorage

Da Helpedia.

If you use ext3: After resizing the disk in XenServer, start the operating system and use the resize2fs tool with the name of the partition that should be extended (refer to the manual for more details). For example to resize a data partition:

#umount /dev/xvdc1
#fdisk /dev/xvdc1
#d (Delete the partition and recreate it)
#n (New partition)
#w (Write out table)
#e2fsck -f /dev/xvdc1
#resize2fs /dev/xvdc1
#mount /dev/xvdc1 /home

To resize the Linux system partition: Shutdown the VM.

Set the VM to boot into single-user mode on the XenServer host CLI Add single to PV-args (boot options in XenCenter)

(for UBUNTU is:)

#xe vm-param-set uuid=6f04... PV-args='-- quiet console=hvc0 partman/default_filesystem=ext3 single'

Boot VM and show disk list make partition table changes in the Linux VM

#fdisk -l
fdisk /dev/xvda


d -Delete Partition
n -New create new partition
p -Primary
1- Partition number
Default values for size
w -Write changes

reboot vm Note: If you need to run FSCK, you must boot from rescue media. Resize the filesystem: resize2fs /dev/xvda1

On XenServer host:

Remove single to PV-args (boot options in XenCenter)

  1. xe vm-param-set uuid=6f04... PV-args='old params...'

If you use xfs: After resizing the disk in XenServer, start the operating system and use the xfs_growfs tool with the name of the partition that should be extended (refer to the manual for more details). For example:

  1. xfs_growfs /dev/xvda1

If you use reiserfs: After resizing the disk in XenServer, start the operating system and use the resize_reiserfs tool with the name of the partition that should be extended (refer to the manual for more details). For example:

  1. resize_reiserfs /dev/xvda1


Attenzione

Ubuntu uses start data @2048 not 63! use fdisk to change start data in partition accordling

Strumenti personali
Namespace
Varianti
Azioni
Navigazione
Strumenti