LinuxQuestions.org
Latest LQ Deal: Linux Power User Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 02-25-2010, 03:49 AM   #1
jonaskellens
Member
 
Registered: Jul 2008
Location: Ghent, Belgium
Distribution: Fedora, CentOS
Posts: 632

Rep: Reputation: 33
Problem with kernel sources


When compiling software I get the following notice :
Quote:
You do not appear to have the sources for the 2.6.31.5xls-domU kernel installed
.

Yum says :

Quote:
Package kernel-headers-2.6.18-164.11.1.el5.x86_64 already installed and latest version
Package kernel-devel-2.6.18-164.11.1.el5.x86_64 already installed and latest version
But uname says :
Code:
-bash-3.2# ls /usr/src/kernels/
2.6.18-164.11.1.el5-x86_64
-bash-3.2# uname -a
Linux vds.hosting.net 2.6.31.5xls-domU #4 SMP Fri Dec 4 12:17:04 CET 2009 x86_64 x86_64 x86_64 GNU/Linux
Extra info :
Quote:
title CentOS (2.6.18-164.11.1.el5xen)
root (hd0,0)
kernel /boot/vmlinuz-2.6.18-164.11.1.el5xen ro root=/dev/xvda1 console=xvc0
initrd /boot/initrd-2.6.18-164.11.1.el5xen.img
This is a VDS I'm renting from my Hosting company.

How can I get the right sources ?? RPMforge repo ??
 
Old 02-25-2010, 05:04 AM   #2
zhjim
Senior Member
 
Registered: Oct 2004
Distribution: Debian Squeeze x86_64
Posts: 1,748
Blog Entries: 11

Rep: Reputation: 233Reputation: 233Reputation: 233
Your mixing up the kernel version. The one that the software ones has a "domU" inside its name. The source you have installed does not.

Take a close look at the uname -a output of yours and you'll see

Code:
uname -a | awk '{print $3}'
 
Old 02-25-2010, 05:45 AM   #3
jonaskellens
Member
 
Registered: Jul 2008
Location: Ghent, Belgium
Distribution: Fedora, CentOS
Posts: 632

Original Poster
Rep: Reputation: 33
Quote:
Originally Posted by zhjim View Post
Your mixing up the kernel version. The one that the software ones has a "domU" inside its name. The source you have installed does not.

Take a close look at the uname -a output of yours and you'll see

Code:
uname -a | awk '{print $3}'
Yes the kernel sources are not the same as the kernel version that is running.

My question : Where do I get the right sources ??
 
Old 02-25-2010, 05:58 AM   #4
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen, DK
Distribution: pclos2016, Slack14.1 Deb Jessie, + 50+ other Linux OS, for test only.
Posts: 16,276

Rep: Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153Reputation: 3153
Quote:
Where do I get the right sources ??
Where did you get the 2.6.31.5xls-domU kernel ? ?

Obviously not a CentOS kernel ....
.. and Googling .. 2.6.31.5xls-domU ..
Or .. linux-2.6.31.5xls-domU ..
.. kernel-2.6.31.5xls-domU ..

provides zero hits !
.....
 
Old 02-25-2010, 06:12 AM   #5
i92guboj
Gentoo support team
 
Registered: May 2008
Location: Lucena, Córdoba (Spain)
Distribution: Gentoo
Posts: 4,063

Rep: Reputation: 381Reputation: 381Reputation: 381Reputation: 381
You can do either of these:
  • Install the sources from the same place you installed the binary kernel, same exact version, and I mean "exact".
  • Install a new kernel and a new source package using the CentOS official package manager and repositories. Probably the easiest and sanest solution unless you are using a custom kernel for a real reason.
  • Compile your own. That way you ensure that your sources and your kernel binary image are in sync.
 
Old 02-25-2010, 06:35 AM   #6
jonaskellens
Member
 
Registered: Jul 2008
Location: Ghent, Belgium
Distribution: Fedora, CentOS
Posts: 632

Original Poster
Rep: Reputation: 33
Quote:
Originally Posted by knudfl View Post
Where did you get the 2.6.31.5xls-domU kernel ? ?
.....
Like I said in my first post : this is a VDS that I'm renting with a hosting company.

I have contacted my hosting company and asked for another kernel to run or to install the sources of the current running kernel version.
 
Old 02-25-2010, 08:30 AM   #7
jonaskellens
Member
 
Registered: Jul 2008
Location: Ghent, Belgium
Distribution: Fedora, CentOS
Posts: 632

Original Poster
Rep: Reputation: 33
This is the file /boot/grub/menu.lst :

Quote:
title CentOS (2.6.18-164.11.1.el5xen)
root (hd0,0)
kernel /boot/vmlinuz-2.6.18-164.11.1.el5xen ro root=/dev/xvda1 console=xvc0
initrd /boot/initrd-2.6.18-164.11.1.el5xen.img
This is /boot :

Code:
-bash-3.2# ls
> config-2.6.18-128.1.6.el5       initrd-2.6.18-164.11.1.el5xen.img  symvers-2.6.18-92.1.18.el5.gz      vmlinuz-2.6.18-164.11.1.el5
> config-2.6.18-164.11.1.el5      initrd-2.6.18-164.el5.img          symvers-2.6.18-92.1.22.el5.gz      vmlinuz-2.6.18-164.11.1.el5xen
> config-2.6.18-164.11.1.el5xen   initrd-2.6.18-92.1.18.el5.img      System.map-2.6.18-128.1.6.el5      vmlinuz-2.6.18-164.el5
> config-2.6.18-164.el5           initrd-2.6.18-92.1.22.el5.img      System.map-2.6.18-164.11.1.el5     vmlinuz-2.6.18-92.1.18.el5
> config-2.6.18-92.1.18.el5       message                            System.map-2.6.18-164.11.1.el5xen  vmlinuz-2.6.18-92.1.22.el5
> config-2.6.18-92.1.22.el5       symvers-2.6.18-128.1.6.el5.gz      System.map-2.6.18-164.el5          xen.gz-2.6.18-164.11.1.el5
> grub                            symvers-2.6.18-164.11.1.el5.gz     System.map-2.6.18-92.1.18.el5      xen-syms-2.6.18-164.11.1.el5
> initrd-2.6.18-128.1.6.el5.img   symvers-2.6.18-164.11.1.el5xen.gz  System.map-2.6.18-92.1.22.el5
> initrd-2.6.18-164.11.1.el5.img  symvers-2.6.18-164.el5.gz          vmlinuz-2.6.18-128.1.6.el5
Code:
-bash-3.2# uname -a
Linux vds.hosting.net 2.6.31.5xls-domU #4 SMP Fri Dec 4 12:17:04 CET 2009 x86_64 x86_64 x86_64 GNU/Linux
Where is this 2.6.31.5xls-domU coming from ???
 
Old 02-25-2010, 10:24 AM   #8
jonaskellens
Member
 
Registered: Jul 2008
Location: Ghent, Belgium
Distribution: Fedora, CentOS
Posts: 632

Original Poster
Rep: Reputation: 33
How do you explain this :

Code:
You do not appear to have the sources for the 2.6.18-164.11.1.el5xen kernel installed.
make[1]: *** [modules] Error 1
-bash-3.2# uname -a
Linux vds.hosting.net 2.6.18-164.11.1.el5xen #1 SMP Wed Jan 20 08:06:04 EST 2010 x86_64 x86_64 x86_64 GNU/Linux
-bash-3.2# ls /usr/src/kernels/
2.6.18-164.11.1.el5-x86_64
Isn't the kernel the same this time ???

Code:
Package kernel-devel-2.6.18-164.11.1.el5.x86_64 already installed and latest version
Package kernel-headers-2.6.18-164.11.1.el5.x86_64 already installed and latest version

Last edited by jonaskellens; 02-25-2010 at 10:27 AM.
 
Old 02-25-2010, 11:11 AM   #9
TB0ne
LQ Guru
 
Registered: Jul 2003
Location: Birmingham, Alabama
Distribution: SuSE, RedHat, Slack,CentOS
Posts: 17,916

Rep: Reputation: 3689Reputation: 3689Reputation: 3689Reputation: 3689Reputation: 3689Reputation: 3689Reputation: 3689Reputation: 3689Reputation: 3689Reputation: 3689Reputation: 3689
Quote:
Originally Posted by jonaskellens View Post
How do you explain this :

Code:
You do not appear to have the sources for the 2.6.18-164.11.1.el5xen kernel installed.
make[1]: *** [modules] Error 1
-bash-3.2# uname -a
Linux vds.hosting.net 2.6.18-164.11.1.el5xen #1 SMP Wed Jan 20 08:06:04 EST 2010 x86_64 x86_64 x86_64 GNU/Linux
-bash-3.2# ls /usr/src/kernels/
2.6.18-164.11.1.el5-x86_64
Isn't the kernel the same this time ???

Code:
Package kernel-devel-2.6.18-164.11.1.el5.x86_64 already installed and latest version
Package kernel-headers-2.6.18-164.11.1.el5.x86_64 already installed and latest version
This:
Quote:
2.6.18-164.11.1.el5xen
isn't the same as this:
Quote:
kernel-devel-2.6.18-164.11.1.el5
Notice the missing "xen" at the end??? And if this is a hosted server, tell the hosting company to install the missing source. You're paying them for support.
 
Old 02-26-2010, 05:28 AM   #10
zhjim
Senior Member
 
Registered: Oct 2004
Distribution: Debian Squeeze x86_64
Posts: 1,748
Blog Entries: 11

Rep: Reputation: 233Reputation: 233Reputation: 233
dunno if you know but a Xen domU does not need to have the kernel inside it's own realm. It only is needed for the dom0 to start it up..

I doubt in this case that you could easily create your own kernel and start it up.

Like TBone sad get the hosting company to provide you the source. Or check out your yum repository. (also i dunno how to query yum for available packages)
 
Old 02-26-2010, 05:53 AM   #11
jonaskellens
Member
 
Registered: Jul 2008
Location: Ghent, Belgium
Distribution: Fedora, CentOS
Posts: 632

Original Poster
Rep: Reputation: 33
Quote:
Originally Posted by TB0ne View Post
Notice the missing "xen" at the end???
The 2.6.31.5xls-domU seems to be coming from a central server. It is setup that way that there is always a kernel to boot, even if I install my own and mess up.

Got my custom kernel now.

Got the right sources by doing "yum install kernel-xen-devel".

All works ok. Thanks for the reply.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
problem installing kernel 2.6.28 from sources in suse 11 iamrohitbanga Linux - General 1 01-04-2009 03:05 AM
problem installing kernel 2.6.28 from sources in suse 11 iamrohitbanga Linux - Newbie 2 01-03-2009 12:59 PM
Problem with unpacking kernel sources Rostfrei Linux - Software 1 06-02-2008 03:55 AM
A post-compilation problem with kernel sources Zibi1981 Linux - Kernel 2 08-04-2007 04:17 AM


All times are GMT -5. The time now is 08:19 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration