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/
Home Products Support Community News


Re: [Xen-users] Re: Xen-users Digest, Vol 77, Issue 15

To: Oliver Wilcock <oliver@xxxxxxx>
Subject: Re: [Xen-users] Re: Xen-users Digest, Vol 77, Issue 15
From: Prakhar Srivastava <prakhar.apj@xxxxxxxxx>
Date: Sun, 10 Jul 2011 13:54:12 +0530
Cc: xen-users@xxxxxxxxxxxxxxxxxxx
Delivery-date: Sun, 10 Jul 2011 01:25:41 -0700
Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=jVJlm7De6v7nPUroma+9leU6LpHYFz78nOYC65oUJuQ=; b=RdHKhrZZH2SG5Qxw5aB1vyC9L42IytFgPRGvkovflkHrUYu0LuGXFYqInxkJNR7apt g9Ravjd5VabILdGJ/PEX1mPYZHu2sglFfK9Z6jiwWurguQ3O/K0aHMUSzUwlKdLaDArz 7Ap6ytWMs3FxAujUk/munEG0VTCwRIl8Kau58=
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <4E18E997.5050903@xxxxxxx>
List-help: <mailto:xen-users-request@lists.xensource.com?subject=help>
List-id: Xen user discussion <xen-users.lists.xensource.com>
List-post: <mailto:xen-users@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=unsubscribe>
References: <20110709190032.D488140E96A3@xxxxxxxxxxxxxx> <4E18E997.5050903@xxxxxxx>
Sender: xen-users-bounces@xxxxxxxxxxxxxxxxxxx
Thanx a lot for the response.
"Populated Xen guest image with Dom0)" - Take a look at�http://download.oracle.com/docs/cd/E11081_01/doc/doc.21/e10898/createvm.htm#CACFCFCG. I have used a file based image and then formatted and mounted it at /mnt. I copied the entire root disk as described using rsync to the file based virtual disk image. Once I have the virtual disk image which i believe should contain the LVM partitions (because the Dom0 system was LVM partitioned), I copy it to a new logical volume (say�/dev/Box1/debian-lvm-image) which then I use to create a xen domU.

I am using the kernel and initrd of th dom0.

disk = [ 'phy:/dev/Box1/debian-lvm-image,xvda,w' ].
and root='/dev/Box1/root

Withing the virtual disk image, the /etc/fstab contains the entries�
/dev/xvda � � � / � � � � � � ��
/dev/xvdb � � � swap
(I use a file based image for swap).

The setup described above does gives an error while booting DomU.
Please let me know if I should clarify further. My overall objective is to run LVM wihin Xen guest VM.


On Sun, Jul 10, 2011 at 5:21 AM, Oliver Wilcock <oliver@xxxxxxx> wrote:
I have used LVM inside a guest VM.

I don't understand your description though.
In particular I don't know what the following means: "Populated Xen guest image with DomO image." �You copied the bits from one LV to the new LV?

If you are trying to avoid installing the guest OS by copying the bits, or the file system from your Dom0, then you are going to need to explain to it were to find root.

If the LV that you created for your guest is /dev/Box1/root then the guest will need to use this name.

i.e. /dev/Box1/root

You will need to pass the entire disk into the guest. �Perhaps:

disk = [ 'phy:/dev/sdb,xvda,w' ]

To override the fstab and initrd expectations of the name of the root file system you can set the kernel parameter in your guest VM configuration. �Perhaps:

Oh, and if the guest is managing the volume group then the Dom0 can't. So before you mount the physical disk in the DomU you need to deactivate it in Dom0.

vgchange -a n /dev/Box1

If I've misunderstood and you are trying to create a nested LVM configuration I think you are going to run into trouble having two volume groups with the same name.

> volume.
� You copied the bits from the

On 2011-07-09 15:00, xen-users-request@lists.xensource.com wrote:
Date: Sat, 9 Jul 2011 22:27:41 +0530
From: Prakhar Srivastava<prakhar.apj@gmail.com>
Subject: [Xen-users] Cannot boot with LVM inside Xen DomU
� � � �<CAF+Dr+tBZg588Y+ZkkFs-nu8dLG_uJP=jQ6+fpLFKwcTjZ1KEw@mail.gmail.com>
Content-Type: text/plain; charset="iso-8859-1"

I have Xen 4.0 installation on Debian Squeeze. I am able to boot Xen guest
based on physical partition but failing to boot Xen guest with LVM within
DomU. To use LVM inside DomU, I took the following way:
1. Installed a basic debian squeeze system on a AMD64 box. Used the entire
disk disk and configure LVM option to set root on LVM. The root is at
/dev/Box1/root and swap is at /dev/Box1/swap_1
2. Installed Xen and Dom0 from repository.
3. Populated Xen guest image with DomO image.

When I try to run the image, I get the error that the volume logical volume
is not found. I have set root to /dev/mapper/root in Xen configuration
Is there anything I am missing. Has anyone used LVM inside Xen guest?


Xen-users mailing list

Xen-users mailing list