Re: [Vserver] CentOS RPM's

From: Matt Paine <matt_at_mattsoftware.com>
Date: Sun 25 Mar 2007 - 23:36:32 BST
Message-ID: <4606F970.7070605@mattsoftware.com>

Hi Daniel

> Sounds somewhat odd, but I've had problems trying to build 2.6.20 on it
> too. Haven't really investigated it yet though.
>
>
>>Has anyone got kernel RPM's with the linux vserver patches installed
>>(vanilla or otherwise) that are build for CentOS4.4? I know Daniel has
>>the fedora kernels, and I've been scouring his rpm repository to find
>>the centos ones with no luck (plenty of util-vserver rpms, but no
>>kernels). I had the thought that the vserver stuff might already be in
>>the kernel (long shot i know, but anythings possible) so I downloaded
>>the util-vserver rpms and tried them, to no avail of course :)
>
>
> The problem with the CentOS kernel is that it's really old and it would
> require major surgery in order to get any sort of recent Linux-VServer
> version on there. I've been playing with the idea of providing more
> recent, vanilla kernel RPMs too, but nothing has come out of that yet,
> mostly because the userspace matches the old kernel. So in order to get a
> recent kernel working nicely, you'd probably need to update at least udev
> and mkinitrd.

That would explain a lot. :) Thanx for the tips

>>I would love to be able to compile a kernel and package it as an RPM,
>>however at the moment my efforts are not being rewarded with anything
>>remotely usable. If someone could help me with compiling the kernel that
>>would be appreciated (I have the logs showing what errors I'm getting).
>
>
> Posting the errors is always a good idea...

Thought it was bit off topic - but here I go....

I'm compiling under root on a VMWare machine. Its a basic CentOS4.4
system, straight from the DVD, with 'yum groupinstall 'Development
Tools' installed. I downloaded the kernel src rpm from
mirror.centos.org, and am simply trying to recompile the kernel that
come with the distro (no packages have been updated - its all straight
from the dvd). Having said that I do have the VMWare Tools installed -
but as far as I'm aware they are drivers for the VMWare machine. If you
are unaware on whats going on i think the next stage might be to go find
a real machine to the build on. But any hints would be great :)

-------console--------------8<------------------------------
[root@build rpmbuild]# rpm -ivh kernel-2.6.9-42.EL.src.rpm

(lots of "buildsvn" group and user no existing, using root)

[root@build rpmbuild]# cd kernel/SPEC/
[root@build SPEC]# rpmbuild -ba --target i686 kernel-2.6.spec \
> build.log 2> build-err.log
---------------------------------->8------------------------

-----build.log--------------8<------------------------------
Building target platforms: i686
Building for target i686
Executing(%prep): /bin/sh -e /root/rpmbuild/kernel/TMP/rpm-tmp.61696
Patch #3 (patch-2.6.9-ac11.bz2):
Patch #4 (linux-2.6.9-selected-ac-bits.patch):

................................

Patch #10002 (linux-2.6.9-slab-update.patch):
Patch #10003 (linux-2.6.9-pci-ids.patch):
`/root/rpmbuild/kernel/SOURCE/kernel-2.6.9-i586-smp.config' ->
`./kernel-2.6.9-i586-smp.config'
`/root/rpmbuild/kernel/SOURCE/kernel-2.6.9-i586.config' ->
`./kernel-2.6.9-i586.config'
`/root/rpmbuild/kernel/SOURCE/kernel-2.6.9-i686-hugemem.config' ->
`./kernel-2.6.9-i686-hugemem.config'
`/root/rpmbuild/kernel/SOURCE/kernel-2.6.9-i686-smp.config' ->
`./kernel-2.6.9-i686-smp.config'
`/root/rpmbuild/kernel/SOURCE/kernel-2.6.9-i686.config' ->
`./kernel-2.6.9-i686.config'
removed `./drivers/isdn/capi/kcapi.c.orig'
removed `./drivers/isdn/capi/capidrv.c.orig'

................................

removed `./sound/pci/intel8x0.c.orig'
removed `./sound/oss/msnd.c.orig'
Executing(%build): /bin/sh -e /root/rpmbuild/kernel/TMP/rpm-tmp.3088
cc linux-2.6.9/scripts/bin2c.c -o linux-2.6.9/scripts/bin2c
BUILDING A KERNEL FOR i686...
   CHK include/linux/version.h
   UPD include/linux/version.h
   CHK include/linux/version.h
   SYMLINK include/asm -> include/asm-i386
   SPLIT include/linux/autoconf.h -> include/config/*
   CHK include/asm-i386/asm_offsets.h
   UPD include/asm-i386/asm_offsets.h
   CHK include/linux/compile.h
   UPD include/linux/compile.h

RPM build errors:
---------------------------------->8------------------------

---------build-err.log------------8<------------------------
+ umask 022
+ cd /root/rpmbuild/kernel/BUILD
+ LANG=C
+ export LANG
+ unset DISPLAY
+ cd /root/rpmbuild/kernel/BUILD
+ rm -rf kernel-2.6.9
+ /bin/mkdir -p kernel-2.6.9
+ cd kernel-2.6.9
+ tar -xf -
+ STATUS=0
+ '[' 0 -ne 0 ']'
++ /usr/bin/id -u
+ '[' 0 = 0 ']'
+ /bin/chown -Rhf root .
++ /usr/bin/id -u
+ '[' 0 = 0 ']'
+ /bin/chgrp -Rhf root .
+ /bin/chmod -Rf a+rX,u+w,g-w,o-w .
+ cd linux-2.6.9
+ echo 'Patch #3 (patch-2.6.9-ac11.bz2):'
+ /usr/bin/bzip2 -d
+ patch -p1 -s
+ STATUS=0
+ '[' 0 -ne 0 ']'
+ echo 'Patch #4 (linux-2.6.9-selected-ac-bits.patch):'
+ patch -p1 -s
+ echo 'Patch #10 (linux-2.6.9-ac-backouts.patch):'
+ patch -p1 -R -s

........................................

+ Config=kernel-2.6.9-i686.config
+ DevelDir=/usr/src/kernels/2.6.9-42.EL-i686
+ KernelVer=2.6.9-42.EL
+ echo BUILDING A KERNEL FOR i686...
+ perl -p -i -e 's/^EXTRAVERSION.*/EXTRAVERSION = -42.EL/' Makefile
+ make -s mrproper
+ cp configs/kernel-2.6.9-i686.config .config
+ make -s nonint_oldconfig
+ make -s include/linux/version.h
+ make -s bzImage
arch/i386/kernel/signal.c: In function `setup_sigcontext':
arch/i386/kernel/signal.c:275: warning: unused variable `eflags'
arch/i386/kernel/setup.c: In function `setup_arch':
arch/i386/kernel/setup.c:1449: warning: implicit declaration of function
`noht_init'
arch/i386/kernel/setup.c:1484: warning: implicit declaration of function
`check_ioapic'
arch/i386/kernel/dmi_scan.c: In function `disable_pci_mmconf_seg':
arch/i386/kernel/dmi_scan.c:260: warning: control reaches end of
non-void function
arch/i386/kernel/dmi_scan.c: In function `disable_ioapic_on_up':
arch/i386/kernel/dmi_scan.c:270: warning: control reaches end of
non-void function
arch/i386/kernel/cpu/intel.c:83: warning: 'num_cpu_cores' defined but
not used
ld: arch/i386/kernel/cpu/common.o: invalid string offset 23771 >= 958
for section `.strtab'
ld: arch/i386/kernel/cpu/common.o: invalid string offset 23820 >= 958
for section `.strtab'
ld: arch/i386/kernel/cpu/common.o: invalid string offset 23843 >= 958
for section `.strtab'
ld: arch/i386/kernel/cpu/common.o: invalid string offset 23871 >= 958
for section `.strtab'
ld: arch/i386/kernel/cpu/common.o: invalid string offset 23901 >= 958
for section `.strtab'

.....(add nausium - many of these errors with different string offsets)
.....(possibly hundreds)

ld: arch/i386/kernel/cpu/common.o: invalid string offset 24234 >= 958
for section `.strtab'
ld: arch/i386/kernel/cpu/common.o: invalid string offset 24234 >= 958
for section `.strtab'
ld: arch/i386/kernel/cpu/common.o: invalid string offset 24234 >= 958
for section `.strtab'
ld: arch/i386/kernel/cpu/common.o: invalid string offset 24234 >= 958
for section `.strtab'
ld: arch/i386/kernel/cpu/cyrix.o: invalid string offset 2049 >= 419 for
section `.strtab'
ld: arch/i386/kernel/cpu/cyrix.o: invalid string offset 2049 >= 419 for
section `.strtab'
ld: arch/i386/kernel/cpu/cyrix.o: invalid string offset 2049 >= 419 for
section `.strtab'
ld: arch/i386/kernel/cpu/cyrix.o: invalid string offset 7681 >= 419 for
section `.strtab'

.....(add nausium - many of these errors with mainly the 2049
.....string offset)(possibly hundreds)

ld: arch/i386/kernel/cpu/cyrix.o: invalid string offset 2049 >= 419 for
section `.strtab'
ld: arch/i386/kernel/cpu/cyrix.o: invalid string offset 2049 >= 419 for
section `.strtab'
ld: arch/i386/kernel/cpu/cyrix.o: invalid string offset 2049 >= 419 for
section `.strtab'
ld: final link failed: Bad value
make[2]: *** [arch/i386/kernel/cpu/built-in.o] Error 1
make[1]: *** [arch/i386/kernel/cpu] Error 2
make: *** [arch/i386/kernel] Error 2
error: Bad exit status from /root/rpmbuild/kernel/TMP/rpm-tmp.3088 (%build)
     Bad exit status from /root/rpmbuild/kernel/TMP/rpm-tmp.3088 (%build)
----------------------------------->8-----------------------

I can attach the log files if you really need it, and if you require any
other information please let me know

Any help or direction would be appreciated.

Thankyou!

Matt.

_______________________________________________
Vserver mailing list
Vserver@list.linux-vserver.org
http://list.linux-vserver.org/mailman/listinfo/vserver
Received on Mon Mar 26 00:03:01 2007

[Next/Previous Months] [Main vserver Project Homepage] [Howto Subscribe/Unsubscribe] [Paul Sladen's vserver stuff]
Generated on Mon 26 Mar 2007 - 00:03:07 BST by hypermail 2.1.8