[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] the /dev/xvda can not be mounted and read/write when using xl create domU



On Wed, 2014-04-16 at 10:47 -0500, Wei Huang wrote:
> On 04/16/2014 10:29 AM, duqi wrote:
> > Hello everyone,
> >
> > I have tried to boot the domU folow the below instrctions:
> > The domU kernel that I used is from 
> > https://github.com/linux-sunxi/linux-sunxi.git  and the 'sunxi-devel' 
> > branch. I  have compiled the ramdisk with the domu kernel to boot the domu.
> >
> > When I xl console the domU , I tried to mount the /dev/xvda to the /mnt and 
> > I met this error:
> > # mount /dev/xvda /mnt
> > [  681.934232] end_request: I/O error, dev xvda, sector 2
> > [  681.934401] EXT3-fs (xvda): error: unable to read superblock
> > [  681.947103] end_request: I/O error, dev xvda, sector 2
> > [  681.947244] EXT2-fs (xvda): error: unable to read superblock
> > [  681.967089] end_request: I/O error, dev xvda, sector 2
> > [  681.967226] EXT4-fs (xvda): unable to read superblock
> > mount: mounting /dev/xvda on /mnt failed: Invalid argument
> > #
> >
> > Then I tried "# dd if=/dev/zero of=/dev/xvda bs=1 count=1000 seek=10000" to 
> > test the read and write of /dev/xvda, it also met error:
> > [  632.851166] end_request: I/O error, dev xvda, sector 16
> > dd: writing '/dev/xvda': Input/output error
> > 1+0 records in
> > 0+0 records out
> >
> > (2) the domu_all.cfg is here:
> > root@linaro-alip:~# cat domu_all.cfg
> > kernel = "/root/zImage"
> > memory = "64"
> > name = "dom11"
> > vcpus = 1
> > serial="pty"
> > root="/dev/xvda"
> > extra = "4 console=hvc0,xencons=tty"
> > disk = [ 'phy:/dev/loop2,xvda,w' ]
> > vif=[ 'mac=00:16:3e:56:af:69,bridge=xenbr0,type=netfront', ]
> 
> Based on the log, I think your loop2 might have problem. If you are 
> using image from Linaro, you should specify the offset in losetup. Here 
> is one:
> 
>  > losetup -o 54525952 /dev/loop2 ./rootfs.img

Or use root=/dev/xvda2 on the guest command line/cfg, which would be
more usual I think.

(I'm not convinced this is the error though, since it seems xvda just
isn't working).

duqi could you post the output of "xenstore-ls -fp" while the guest is
running but not able to access its disk.

What is your rootfs device? (IOW what physical medium contains
rootfs.img)
 
> You can also try to mount /dev/loop2 in Dom0.

Yes, that would be a useful sanity check.

Ian.



_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.