On Tue, Jun 05, 2007 at 10:56:00AM -0700, Brian Lavender
wrote:> On Mon, May 28, 2007 at 08:39:49AM -0400, Thomas Kocourek wrote:
> > I have been using QEMU for some time and the virtual machine works
very
> > well. Is there a way to copy over the virtual machine from QEMU to
XEN?
>
> I was just thinking about this. Did anyone give details? Seems like you
> ought to be able to create a config file, put a Xen kernel in, and be
> good to go. I am about to try it, but I thought I would ask if you had
> success, so I could avoid the similar mistakes.
>
> apt-get install xen-linux-system-2.6.18-4-xen-686
>
> Oops, I just used the Debian way. This is a Fedora list. Let''s
just
> pretend you want a Debian image then.
>
> yum install kernel-xen.i686
>
> and then create a config file for the image, similar to this howto.
>
> http://wiki.rpath.com/wiki/Xen_DomU_Guide
>
> I''ll give it a shot and see if it works!
I created the machine using QEMU using a raw file system and it booted in
Xen, but I am not getting networking to come up. I don''t see a
networking
device. How do I get networking to appear?
[root@localhost xen]# xm create -c debian
Using config file "./debian".
WARNING:root:Unknown image directive savedefault
WARNING:root:Unknown image directive savedefault
WARNING:root:Unknown image directive savedefault
Going to boot Debian GNU/Linux, kernel 2.6.18-4-xen-686
kernel: /boot/vmlinuz-2.6.18-4-xen-686
initrd: /boot/initrd.img-2.6.18-4-xen-686
Started domain debian
Linux version 2.6.18-4-xen-686 (Debian 2.6.18.dfsg.1-12etch2)
(dannf@debian.org) (gcc version 4.1.2 20061115 (prerelease) (Debian
4.1.1-21)) #1 SMP Thu May 10 03:24:35 UTC 2007
After my Debian VM boots, I get this kernel message.
debian:/lib/modules/2.6.18-4-xen-686# dmesg | grep eth
netfront: Initialising virtual ethernet driver.
netfront: device eth0 has flipping receive path.
Here is my xen config file
{{{
# Automatically generated xen config file
name = "debian"
memory = "512"
disk = [ ''tap:aio:/var/lib/xen/images/debian2.img,hda,w'', ]
vif = [ ''mac=00:16:3e:5c:87:5f, bridge=xenbr0'', ]
uuid = "fc23be35-40d8-4fc4-8708-5f6ffb3f5e66"
bootloader="/usr/bin/pygrub"
vcpus=1
on_reboot = ''restart''
on_crash = ''restart''
}}}
And the process I used to build the image using QEMU.
{{{
qemu-img create -f raw debian.img 5G
qemu -cdrom ../../iso/debian-40r0-i386-netinst.iso -hda debian.img -m
256 -boot d
qemu -hda debian.img -m 384
}}}
--
Brian Lavender
http://www.brie.com/brian/