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] Root fs image crated by Yast Xen

To: xen-users@xxxxxxxxxxxxxxxxxxx
Subject: Re: [Xen-users] Root fs image crated by Yast Xen
From: TAIRA Hajime <htaira@xxxxxxxxx>
Date: Mon, 5 Jun 2006 01:08:35 +0900
Delivery-date: Sun, 04 Jun 2006 09:09:19 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <4480E5AC.6000000@xxxxxxxxxxxxxxx>
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/cgi-bin/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=unsubscribe>
References: <4480E5AC.6000000@xxxxxxxxxxxxxxx>
Sender: xen-users-bounces@xxxxxxxxxxxxxxxxxxx
Hi, Noniko.

I fitted same thing. When I was verifying Xen on SLES10 Beta.

/var/lib/xen/images/vm1/hda. Wonderful.

It is whole disk image.

I tried to loopback mount in order to see what is in this image file.
But I can't. The error message is:

mount: wrong fs type, bad option, bad superblock on /dev/loop0,
missing codepage or other error

This error is correct. Because hda is not filesystem.
Please try following step.

1. Mapping hda to /dev/loop0.
# losetup /dev/loop0 /var/lib/xen/images/vm1/hda

2. Look at geometric information on /dev/loop0.
# fdisk -l -u /dev/loop0
Disk /dev/hda: 30.7 GB, 30738677760 bytes
255 heads, 63 sectors/track, 3737 cylinders, total 60036480 sectors
Units = sectors of 1 * 512 = 512 bytes

   Device Boot      Start         End      Blocks   Id  System
/dev/loop0p1           63      208844      104391   83  Linux
/dev/loop0p2       208845    60034904    29913030   83  Linux

3. Calculate the offset. offset = Start x Unit size
# offset=((63*512))

4. Mapping hda1 in /dev/loop0
# losetup -o $offset /dev/loop1 /dev/loop1

5. Mount /dev/loop1 to /mnt/vm1_hda1
# mkdir /mnt/vm1_hda1
# mount /dev/loop1 /mnt/vm1_hda1

That's all.

.::.:... .::....: .::...:: .::.:.:: .::..:.: .:::..:.
TAIRA Hajime <htaira@xxxxxxxxx>
             web: http://pantora.net/

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