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: AW: [Xen-users] debian Lenny -> Squeeze domU mdX software raidmigrat

To: xen-users@xxxxxxxxxxxxxxxxxxx
Subject: Re: AW: [Xen-users] debian Lenny -> Squeeze domU mdX software raidmigration - failed to assemble arrays
From: Simon Hobson <linux@xxxxxxxxxxxxxxxx>
Date: Thu, 5 May 2011 11:10:15 +0100
Delivery-date: Thu, 05 May 2011 05:40:15 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <6B73AB901767CA49B818C7A071E03FAC609266@xxxxxxxxxxxxxxxxx>
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: <6B73AB901767CA49B818C7A071E03FAC609266@xxxxxxxxxxxxxxxxx>
Sender: xen-users-bounces@xxxxxxxxxxxxxxxxxxx
netz-haut - stephan seitz wrote:

to make transitions more convenient, I've done this by using uuid instead of device names.
If you ls -l /dev/disk/by-uuid inside your domU, you'll see something like

lrwxrwxrwx 1 root root 10 5. Mai 07:38 39a2a64b-0716-47ad-92f4-a7437cac54ee -> ../../sda2 lrwxrwxrwx 1 root root 10 5. Mai 07:38 e8b97b59-a790-417c-8231-fe8da8b6e6ee -> ../../sda1

In /etc/fstab inside the domU, '/dev/sda2' would be replaced by 'UUID=39a2a64b-0716-47ad-92f4-a7437cac54ee' and '/dev/sda1' by 'UUID=e8b97b59-a790-417c-8231-fe8da8b6e6ee'

If pvgrub or pygrub is used, the devicename needs to be replaced inside the domU in /boot/grub/menu.lst from e.g. 'root=/dev/sda2' to 'root=UUID=39a2a64b-0716-47ad-92f4-a7437cac54ee'

If, like in your case, the domU kernel is directly booted by a cfg statement, the root statement needs to be changed in the cfg file by using the the same formatting as in the menu.lst above.

Now, it doesn't matter any longer if the device is called xvda or sda or (ancient but possible) hda.

Would using labels be more convenient ? At least on ext2/3, dunno about others.

If you should move a guest to another host, or rebuild it's filesystem for any reason, setting a label on the filesystem is probably easier than finding the places (multiple - Dom0 and DomU) places the UUID has been used.

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

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