Hi, I have created a complete clone of my hard disk using dd and now i want to put this on a domU, is this possible? I have been reading and testing but i am still unable to make this work. This is my cfg file but something is wrong because when i try to create the VM it says ''Error: (2, ''Invalid kernel'', ''xc_dom_find_loader: no loader found\n'')'' name = ''test-rawimage'' memory = ''256'' disk = [ ''tap:aio:/mnt/disk-lappy.img,xvda,w'' ] vif = [ '''' ] bootloader = ''/usr/bin/pygrub'' on_reboot = ''restart'' on_crash = ''restart'' I have also specified the kernel and ramdisk options but i get "Error: Boot loader didn''t return any data!" Can anyone help on this? I would really appreciate.. Ricardo _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
I have managed to start the domain but changing to cfg file, but it dies with a kernel panic Errors: XENBUS: Device with no driver: device/vbd/51712 XENBUS: Device with no driver: device/vif/0 XENBUS: Device with no driver: device/console/0 drivers/rtc/hctosys.c: unable to open rtc device (rtc0) (......) Creating root device. Mounting root filesystem. mount: could not find filesystem ''/dev/root'' Setting up other filesystems. Setting up new root fs setuproot: moving /dev failed: No such file or directory no fstab.sys, mounting internal defaults setuproot: error mounting /proc: No such file or directory setuproot: error mounting /sys: No such file or directory Switching to new root and running init. unmounting old /dev unmounting old /proc unmounting old /sys switchroot: mount failed: No such file or directory Booting has failed. Kernel panic - not syncing: Attempted to kill init! cfg file: name = ''test-rawimage'' kernel = ''/boot/vmlinuz-2.6.21.7-3.fc8xen'' # Dom0 kernel ramdisk = ''/boot/initrd-2.6.21.7-3.fc8xen.img'' # Dom0 ramdisk memory = ''256'' disk = [ ''file:/mnt/disk-lappy.img,xvda,w'' ] vif = [ '''' ] #bootloader = ''/usr/bin/pygrub'' #Commented on_reboot = ''restart'' on_crash = ''restart'' I have seen this problem in the list before and there is a solution but i don''t remember.. Ricardo On Mon, May 26, 2008 at 1:34 AM, Ricardo Tiago <rtiago@gmail.com> wrote:> Hi, > > I have created a complete clone of my hard disk using dd and now i > want to put this on a domU, is this possible? > > I have been reading and testing but i am still unable to make this work. > > This is my cfg file but something is wrong because when i try to > create the VM it says ''Error: (2, ''Invalid kernel'', > ''xc_dom_find_loader: no loader found\n'')'' > > name = ''test-rawimage'' > memory = ''256'' > disk = [ ''tap:aio:/mnt/disk-lappy.img,xvda,w'' ] > vif = [ '''' ] > bootloader = ''/usr/bin/pygrub'' > on_reboot = ''restart'' > on_crash = ''restart'' > > I have also specified the kernel and ramdisk options but i get "Error: > Boot loader didn''t return any data!" > > Can anyone help on this? > I would really appreciate.. > > Ricardo >_______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Hi Ricardo, On Sun, May 25, 2008 at 8:02 PM, Ricardo Tiago <rtiago@gmail.com> wrote:> I have managed to start the domain but changing to cfg file, but it > dies with a kernel panicIt seems to me that you should be able to use the dd image of the disk. You are leaving out a key bit of information that would have made it easier to answer the question. What is on the disk? I will assume the answer is Linux and probably Fedora or the like. The solution has to deal with the root= option on the kernel command line. You may also need to adjust the /etc/fstab file in the image as well. You need to specify in the guest config the proper root= line. You can get a good sense of this from the grub.conf file from the original disk. However you may still need to modify the disk image itself to make things work. For this you should you losetup to associate the disk image with a loopback device and then use kpartx -av to make the partions available. You can then work with the mapped partitions in /dev/mapper just as you would normal Linux partitions. One other simple, but potentially non-ideal is to treat the guest as an hvm guest and boot it as such, but that would have performance degradation. I also should mentioned that we covered the converting of a existing partition to a domU in our book[1]. We also covered in a lot of detail working with the disk and partition images, losetup, kpartx, dd, etc. I learned a lot from the writing a book on xen experience and there is a lot of fundamental knowledge to be gained from it. I am unsure if I gave you enough information to solve your problem completely. It will depend on the support in the fedora Xen kernel for your desired domU (i.e if you need LVM support, etc.). It also depends on how tricky it is to boot your existing system image. Feel free to post the details of where you get stuck in the rest of the process of converting the image the rest of the way to a domU. Hope that gets you started in the right direction. By the way, the pygrub trick in your first post didn''t work probably since you are booting a kernel in that disk image that is not Xen compatible. Either that or pygrub wasn''t able to properly read into the disk to get the grub info. Cheers, Todd [1] http://runningxen.com _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
---------- Forwarded message ---------- From: Ricardo Tiago <rtiago@gmail.com> Date: Tue, May 27, 2008 at 9:59 AM Subject: Re: [Xen-users] Re: Raw Disk Image to domU To: deshantm@gmail.com Hi Todd, Thank you for your help, i have managed to build the image by rebuilding the initrd (omiting scsi, raid and lvm modules) and adding the root option to my cfg. One thing that i don''t understand is the difference of sda, xvda and when to use one or the other in the cfg. Ricardo _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
---------- Forwarded message ---------- From: Ricardo Tiago <rtiago@gmail.com> Date: Tue, May 27, 2008 at 2:21 PM Subject: Re: [Xen-users] Re: Raw Disk Image to domU To: deshantm@gmail.com I didn''t previously noted but while the image boots fine, that are still some errors.. XENBUS: Device with no driver: device/vbd/51712 XENBUS: Device with no driver: device/vif/0 The ramdisk was build like this.. mkinitrd -f --preload=xenblk --with=xenblk --with=ext3 --with=jbd --with=ata_piix --with=libata --with=e1000 --with=i2c_i801 --with=i2c_core --with=bridge --with=netloop --with=ipv6 --with=ip_tables --with=iptable_filter --with=loop --omit-scsi-modules --omit-raid-modules --omit-lvm-modules $INITRD_NAME $KERNEL Did i miss something? Ricardo On Tue, May 27, 2008 at 9:59 AM, Ricardo Tiago <rtiago@gmail.com> wrote:> Hi Todd, > > Thank you for your help, i have managed to build the image by rebuilding > the initrd (omiting scsi, raid and lvm modules) and adding the root option > to my cfg. > > One thing that i don''t understand is the difference of sda, xvda and when > to use one or the other in the cfg. > > Ricardo > > > > > >_______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Hi Ricardo,> One thing that i don''t understand is the difference of sda, xvda and when to > use one or the other in the cfg.This is starting to blur more and more. As I originally understood it, sd* was for SCSI and xvd* was for Xen block device. This would allow the guest to be given a SCSI device and the the driver would be the standard SCSI driver when passed sda and the xen blk driver when passed a xvd* device. For the most part this is true in general, but for PV guests it seems that Xen does a good job of using possibly the same driver (I am not actually 100% sure of the current status). I think that specifying sd*, hd*, xvd* is more important for HVM guests, since these guests need to provide the drivers in way or another themselves. I would love if others could explain this with more authority and more clearly...> didn''t previously noted but while the image boots fine, that are still some errors..> XENBUS: Device with no driver: device/vbd/51712 > XENBUS: Device with no driver: device/vif/0Did you have problems with anything not working? Does the disk and network work? I have noticed errors similar to this, especial for the console, and the console still works. Cheers, Todd _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
> > > XENBUS: Device with no driver: device/vbd/51712 > > XENBUS: Device with no driver: device/vif/0 > > Did you have problems with anything not working? > > Does the disk and network work? > > I have noticed errors similar to this, especial for the console, and the > console > still works.Yep, i''m having problems with the network...maybe i missed some module when building initrd? Thank you, Ricardo _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
On Tue, May 27, 2008 at 10:34 AM, Ricardo Tiago <rtiago@gmail.com> wrote:> >> >> > XENBUS: Device with no driver: device/vbd/51712 >> > XENBUS: Device with no driver: device/vif/0 >> >> Did you have problems with anything not working? >> >> Does the disk and network work? >> >> I have noticed errors similar to this, especial for the console, and the >> console >> still works. > > Yep, i''m having problems with the network...maybe i missed some module when > building initrd? >When you say problems, can you go into more detail? For example, do you mean that an ifconfig -a doesn''t show the ethX? You should be able to find the netfront driver in /lib/modules/<xen kernel version>/kernel/drivers/ (I''m not sure what it is called and it probably depends on the kernel version you are running) Cheers, Todd _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
On Tue, May 27, 2008 at 11:08 AM, Ricardo Tiago <rtiago@gmail.com> wrote:> Ifconfig -a shows up eth0.So it seems that the driver is being loaded at least. What doesn''t work? sometimes there is an ethtool workaround needed something like: ethtool - K eth0 tx off ref: http://www.nabble.com/ethtool---K-eth0-tx-off-td17471446.html Cheers, Todd _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Ok, i now have network. :) I still have those errors during boot, but everything seems to ''work''. Thank you once again for your support. Ricardo On Tue, May 27, 2008 at 5:12 PM, Todd Deshane <deshantm@gmail.com> wrote:> On Tue, May 27, 2008 at 11:08 AM, Ricardo Tiago <rtiago@gmail.com> wrote: > > Ifconfig -a shows up eth0. > > So it seems that the driver is being loaded at least. > > What doesn''t work? sometimes there is an ethtool workaround needed > something > like: > > ethtool - K eth0 tx off > ref: http://www.nabble.com/ethtool---K-eth0-tx-off-td17471446.html > > Cheers, > Todd >_______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users