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] Xen 3.2 & CentOS

To: joris@xxxxxxxxx
Subject: Re: [Xen-users] Xen 3.2 & CentOS
From: John Morris <jman@xxxxxxxxxxx>
Date: Tue, 11 Mar 2008 08:43:35 +0800
Cc: Xen-users@xxxxxxxxxxxxxxxxxxx
Delivery-date: Mon, 10 Mar 2008 17:44:36 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <47D53CD7.8080802@xxxxxxxxxxx>
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: <32681570.61204096070870.JavaMail.root@xxxxxxxxxxxxxxxxxxx> <47D53CD7.8080802@xxxxxxxxxxx>
Sender: xen-users-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Thunderbird 2.0.0.9 (Windows/20071031)
Joris, I'm replying on list so that the next person might get the benefit.

The patch probably got munged going through email. Look at it carefully, though, I'm only changing one or two important lines. The most important one is this:

mv %{buildroot}%{_prefix}/lib/xen/boot %{buildroot}%{_libdir}/%{name} # put hvmloader in the right place

Look at the below patch to see where it belongs; it needs to go in after 'make install-tools install-docs' in the %install section.

On RH, %{_libdir} expands to /usr/lib on 32-bit, and /usr/lib64 on 64-bit. Nothing tricky.

Good luck.

   John


Hi John

I'm really sorry to ask a very dumb question, but I've been trying to apply that patch you wrote and all I am getting is:
[root@corrin SPECS]# cat xen.patch | patch
patching file xen.spec
patch: **** malformed patch at line 4: Summary: Xen is a virtual machine monitor

I'm sure I'm doing something really n00b but can you please give me a pointer what it is.
Heaps of thanks
Joris


John Morris wrote:
--[ UxBoD ]-- wrote:
http://bits.xensource.com/oss-xen/release/3.2.0/centos-5.1/xen-3.2.0-0xs.centos5.src.rpm

I just built it from source and then installed the built RPM from /usr/src/redhat/RPMS. It worked a treat; no more crashes with 32bit DomUs in a 64bit Dom0 :D
UxBoD,

Thanks for this advice; it worked nicely, with only a couple of hiccups:

1. Had the same trouble another poster in this thread had with the hvmloader going in the wrong place, or not being picked up by the %files section, anyway. Hvmloader is actually a statically-linked, 32-bit ELF executable, so it's unclear whether it should go by itself in /usr/lib/xen/boot or with the other 64-bit stuff in /usr/lib64/xen/boot. I opted for the latter, since it's cleaner, but don't forget to fix your hvm domU config files ('kernel = "/usr/lib64/xen/boot/hvmloader"'). See the patch below. Alternatively, you could put a %if condition to test the arch to fix the %files section.

2. The RPM doesn't fix /etc/grub.conf; be sure to go in there and make sure that the 'kernel' command references the new xen.gz-3.2 image installed with the new xen package instead of the old one installed with the kernel-xen RPM, eg.:

   title CentOS-newxen (2.6.18-53.1.13.el5xen)
           root (hd0,0)
           kernel /xen.gz-3.2 dom0_mem=262144
           module /vmlinuz-2.6.18-53.1.13.el5xen ro root=/dev/dom0/root
           module /initrd-2.6.18-53.1.13.el5xen.img


Thanks again.

   John


=========== cut here ================
--- xen.spec.orig    2008-03-10 21:12:22.000000000 +0800
+++ xen.spec    2008-03-10 21:41:23.000000000 +0800
@@ -3,7 +3,7 @@
Summary: Xen is a virtual machine monitor
Name:    xen
Version: 3.2.0
-Release: 0xs%{?dist}
+Release: 1xs%{?dist}
Group:   Development/Libraries
License: GPL
URL:     http://www.cl.cam.ac.uk/Research/SRG/netos/xen/index.html
@@ -113,7 +113,8 @@

%install
rm -rf %{buildroot}
-make XENFB_TOOLS=y XEN_PYTHON_NATIVE_INSTALL=1 DESTDIR=%{buildroot} prefix=/usr install-tools install-docs +make XENFB_TOOLS=y XEN_PYTHON_NATIVE_INSTALL=1 DESTDIR=%{buildroot} prefix=%{_prefix} install-tools install-docs +mv %{buildroot}%{_prefix}/lib/xen/boot %{buildroot}%{_libdir}/%{name} # put hvmloader in the right place
mkdir -p %{buildroot}%{_localstatedir}/lib/%{name}/xend-db/domain
mkdir -p %{buildroot}%{_localstatedir}/lib/%{name}/xend-db/vnet
mkdir -p %{buildroot}%{_localstatedir}/lib/%{name}/xend-db/migrate
@@ -183,11 +184,6 @@
%{python_sitearch}/grub
%{_libdir}/%{name}
%{_mandir}/man?/*.?.gz
-%dir /usr/lib/xen
-%ifnarch ia64
-# %dir /usr/lib/xen/boot
-# /usr/lib/xen/boot/hvmloader
-%endif
%{_datadir}/%{name}/*.dtd
%dir %{_datadir}/%{name}/qemu
%{_datadir}/%{name}/qemu/keymaps/*
@@ -222,6 +218,10 @@
%{_libdir}/*.a

%changelog
+* Mon Mar 10 2008 John Morris <jman@xxxxxxxxxxx> - 3.2.0-1xs
+- fix hvmloader location depending on arch
+- pick up /usr/lib/xen or /usr/lib/xen64 correctly in %files depending on arch
+
* Thu Jan 10 2008 Ian Jackson <Ian.Jackson@xxxxxxxxxxxxx> - 3.2.0-0xs.centos5 - Xen 3.2, built from 3.2 tree and heavily modified Centos (RHEL) patches.

================== cut here ====================

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


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

<Prev in Thread] Current Thread [Next in Thread>