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

[Xen-users] Compiling lInux2.6.28.5 for hosting VM


  • To: xen-users@xxxxxxxxxxxxxxxxxxx
  • From: KARTHIK BALAJI G <findkb@xxxxxxxxx>
  • Date: Tue, 17 Feb 2009 20:46:39 -0500
  • Delivery-date: Tue, 17 Feb 2009 17:47:30 -0800
  • Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=KvGQSf7L8s27i3qB08OzzcI7zXLjvvd8e+Vx45yMf/5IaMEc8KB+FJoENRtCtAucCw MX1ajaCiavaBw7VOvgAXzZZQlFRqBdPU5F3qTHteD9QuKUlv0MZ0NuM1o8NMCpzeQHvC uMCE5BCGdlIfJiw4vqDH2aYso/N5s6zvve6AA=
  • List-id: Xen user discussion <xen-users.lists.xensource.com>

Hi All,

I am running xen-3.3.1. I am trying to compile linux kernel 2.6.28.5 such that I can boot it as DomU kernel. I enabled all the config options related to xen in that kernel. After compiling the kernel and creating the initrd image I created my xen conf file that looks like,

kernel = "/boot/vmlinuz-2.6.28.5"
ramdisk = "/boot/initrd.img-2.6.28.5"
builder='linux'
memory = 256
name = "guest1"
vcpus = 2
vif = [ 'mac=00:16:3e:ef:fe:11, ip="<my-ip>"' ]
disk = [ 'file:/mnt/domains/vm1/disk.img,sda1,w' ,  'file:/mnt/domains/vm1/swap,sda2,w' ]
root = "/dev/sda1 ro"
>on_reboot   = 'restart'
on_crash    = 'restart'

When I boot into it hangs at,

>Done.
>Begin: Waiting for root file system... ...

So eventually it could not find the root file system and falls to busybox. I did cat /proc/partitions - It listed xvda1 and xvda2 as partitions. I don't understand which driver is missing in kernel 2.6.28.5 to load xvda1. I did some googling and saw that I need to compile unmodified_drivers (present in xen-3.3.1 directory) for this linux kernel. So did,

>cd xen-3.3.1/unmodified_drivers/linux-2.6
>export XL=/root/linux-2.6.28.5
>./mkbuildtree

It created symlinks to the xen files in linux-2.6.28.5 tree. I did "make" and it is throwing whole bunch of errors.

unmodified_drivers/linux-2.6/balloon/balloon.c:101:58: error: macro "DECLARE_WORK" passed 3 arguments, but takes just 2
unmodified_drivers/linux-2.6/balloon/balloon.c:101: warning: type defaults to 'int' in declaration of 'DECLARE_WORK'
unmodified_drivers/linux-2.6/balloon/balloon.c: In function 'balloon_alarm':
unmodified_drivers/linux-2.6/balloon/balloon.c:186: error: 'balloon_worker' undeclared (first use in this function)
unmodified_drivers/linux-2.6/balloon/balloon.c:186: error: (Each undeclared identifier is reported only once
unmodified_drivers/linux-2.6/balloon/balloon.c:186: error: for each function it appears in.)
unmodified_drivers/linux-2.6/balloon/balloon.c: In function 'increase_reservation':
unmodified_drivers/linux-2.6/balloon/balloon.c:240: error: unknown field 'address_bits' specified in initializer
unmodified_drivers/linux-2.6/balloon/balloon.c:240: warning: excess elements in struct initializer
unmodified_drivers/linux-2.6/balloon/balloon.c:240: warning: (near initialization for 'reservation')

I am not familiar with xen. Could someone please tell if I am on the right track? The DomU linux kernel (linux-2.6.18) that got compiled along with xen boots seemlessly. Can we compile custom kernels for xen like what I am doing ? Or we just have to stick with linux-2.6.18 to host VM's ?

Thanks,

-Karthik


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

 


Rackspace

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