WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-users

Re: [Xen-users] how to add space do LVM based DomU

Tapas Mishra wrote:

 I want to know
1) How can I add space to LVM based DomU ?
2) How can I remove a LVM based DomU

Hmm, more than a bit vague there - I'll have to make a few assumptions.

1) Assuming that you mean the DomU is stored in LVM logical volumes defined in Dom0 and exported as block devices to the DomU then :

In Dom0, use LVM to expand the LV - eg "lvm lvresize -L +5G /dev/vg0/somedomurootlv" to add 5G.

Shutdown the DomU, and use the appropriate filesystem tool to resize the filesystem. Eg, for Ext2/Ext3, it's "resize2fs /dev/vg0/somedomurootlv". You'll need to fsck it first, eg "fsck -f /dev/vg0/somedomurootlv"

Startup the DomU, it should now have a larger filesystem available to it.

If on the other hand, you are exporting a single block device and then running LVM within the DomU, you'll need to resize the Dom0 LVM, shutdown and restart the DomU to recognise the change, use a partitioning tool to extend the endpoint of the partition holding the LVM physical device to use the extra space, and then resize the logical volumes as required within the DomU. I'm not entirely certain of the exact sequence of tools to run, and the exact syntax, to do this.

2) Fairly simple - stop the DomU, delete the logical volume(s) it uses.

--
Simon Hobson

Visit http://www.magpiesnestpublishing.co.uk/ for books by acclaimed
author Gladys Hobson. Novels - poetry - short stories - ideal as
Christmas stocking fillers. Some available as e-books.

_______________________________________________
Xen-users mailing list
Xen-users@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-users

<Prev in Thread] Current Thread [Next in Thread>