LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Gentoo
User Name
Password
Gentoo This forum is for the discussion of Gentoo Linux.

Notices

Reply
 
Search this Thread
Old 03-07-2012, 03:14 PM   #1
linux_sonic
Member
 
Registered: Nov 2009
Location: greece
Distribution: Gentoo, Backtrack
Posts: 50

Rep: Reputation: 1
Question problem with my kernel


Hi to all

I am tring to install gentoo 3.2.1-gentoo-r2 and i have problem with my kernel.
When i execute this command: time make -j2 i have this error
usr/initramfs_data.S:1:0: error: CPU you selected does not support x86-64 instruction set

I have tried all the processor families but i have the same error

I have pentium r cpu
Here is my cpu:
Code:
processor	: 0
vendor_id	: GenuineIntel
cpu family	: 6
model		: 23
model name	: Intel(R) Pentium(R)  CPU       E5200  @ 2.50GHz
stepping	: 10
cpu MHz		: 2499.598
cache size	: 2048 KB
physical id	: 0
siblings	: 2
core id		: 0
cpu cores	: 2
apicid		: 0
initial apicid	: 0
fpu		: yes
fpu_exception	: yes
cpuid level	: 13
wp		: yes
flags		: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx lm constant_tsc arch_perfmon pebs bts rep_good nopl aperfmperf pni monitor tm2 ssse3 lahf_lm dts
bogomips	: 4999.19
clflush size	: 64
cache_alignment	: 64
address sizes	: 36 bits physical, 48 bits virtual
power management:

processor	: 1
vendor_id	: GenuineIntel
cpu family	: 6
model		: 23
model name	: Intel(R) Pentium(R)  CPU       E5200  @ 2.50GHz
stepping	: 10
cpu MHz		: 2499.598
cache size	: 2048 KB
physical id	: 0
siblings	: 2
core id		: 1
cpu cores	: 2
apicid		: 1
initial apicid	: 1
fpu		: yes
fpu_exception	: yes
cpuid level	: 13
wp		: yes
flags		: fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe syscall nx lm constant_tsc arch_perfmon pebs bts rep_good nopl aperfmperf pni monitor tm2 ssse3 lahf_lm dts
bogomips	: 4999.63
clflush size	: 64
cache_alignment	: 64
address sizes	: 36 bits physical, 48 bits virtual
power management:
Please help me
 
Old 03-08-2012, 11:41 AM   #2
mitofik
LQ Newbie
 
Registered: Sep 2008
Posts: 14

Rep: Reputation: 1
Either select a proper processor family under "Processor Type and Features" in kernel config (you could use generic x86-64) or post the config you're trying to compile that kernel with so we could see what may be the problem.

Does it compile with default config?
 
Old 03-08-2012, 11:41 AM   #3
mulyadi.santosa
Member
 
Registered: Sep 2011
Posts: 96

Rep: Reputation: 14
Hi

your gcc could help to find the right CPU model for you

Try execute:
Quote:
echo "" | gcc -E -march=native -v - | grep -C 1 -i cc
you'll see gcc spelling out options that it thinks will fit your CPU model. The simply use that for your kernel config.

Hope it helps...
 
Old 03-09-2012, 03:02 AM   #4
i92guboj
Gentoo support team
 
Registered: May 2008
Location: Lucena, Córdoba (Spain)
Distribution: Gentoo
Posts: 4,036

Rep: Reputation: 372Reputation: 372Reputation: 372Reputation: 372
Are you using a source tree that you previously used in some other architecture? This can happen sometimes when you've used x86 on a 64 bits cpu, and later you decide to migrate.

Leftovers could be cleaned up with "make clean", or more in depth, with "make mrproper", but that will erase your .config file as well, so be sure to back it up. If you want to use it, in any case, make sure you use "make oldconfig" after putting it back after the cleaning, to fix any inconsistency.

If that's not it, I would erase the whole tree, and redownload and install it again. Of course, always save your .config if you tuned it yourself. Otherwise, just use genkernel.
 
Old 03-09-2012, 09:09 AM   #5
colorpurple21859
Senior Member
 
Registered: Jan 2008
Location: florida
Distribution: slackware64-current, puppy, ubuntu
Posts: 1,342

Rep: Reputation: 184Reputation: 184
what is in your /etc/make.conf
 
Old 03-09-2012, 12:58 PM   #6
i92guboj
Gentoo support team
 
Registered: May 2008
Location: Lucena, Córdoba (Spain)
Distribution: Gentoo
Posts: 4,036

Rep: Reputation: 372Reputation: 372Reputation: 372Reputation: 372
Settings in make.conf only are only for portage. Just invoking "make" in command line won't source that file. So, the CFLAGS in there are really not relevant (and that error message has nothing to do with them anyway).
 
Old 03-09-2012, 01:29 PM   #7
colorpurple21859
Senior Member
 
Registered: Jan 2008
Location: florida
Distribution: slackware64-current, puppy, ubuntu
Posts: 1,342

Rep: Reputation: 184Reputation: 184
This is what I do know, I can download a kernel from kernel.org and place it in puppylinux run make menuconfig and get every processor from i386 to the 64 bit processors, take the same clean kernel put it on slackware64 or any other 64bit system and only get options for 64bit processors. So if the op has a 32bit processor and only getting options for 64bit processors then the options for processor has to be determined by something external to the kernel itself such as a make configuration file of some sort. When initially installing gentoo the type of arch installing on is set in the /etc/make file, so was thinking that might be the problem.

Last edited by colorpurple21859; 03-09-2012 at 01:43 PM.
 
Old 03-10-2012, 01:59 AM   #8
i92guboj
Gentoo support team
 
Registered: May 2008
Location: Lucena, Córdoba (Spain)
Distribution: Gentoo
Posts: 4,036

Rep: Reputation: 372Reputation: 372Reputation: 372Reputation: 372
Quote:
Originally Posted by colorpurple21859 View Post
This is what I do know, I can download a kernel from kernel.org and place it in puppylinux run make menuconfig and get every processor from i386 to the 64 bit processors, take the same clean kernel put it on slackware64 or any other 64bit system and only get options for 64bit processors. So if the op has a 32bit processor and only getting options for 64bit processors then the options for processor has to be determined by something external to the kernel itself such as a make configuration file of some sort. When initially installing gentoo the type of arch installing on is set in the /etc/make file, so was thinking that might be the problem.
Part of the purpose of running make menuconfig is configuring the source tree, before compiling it. If you have already ran menuconfig in another box then the source tree is at least partly configured for that cpu, which can result in odd things when you move the configured tree to another architecture (even if it's just from x86 to amd64 in the same box). The kind of message s/he's getting there often appears in such kind of scenario.

Of course, it could also be just regular file system corruption, or a manually messed .config file. I can't be sure.
 
Old 03-10-2012, 08:15 AM   #9
colorpurple21859
Senior Member
 
Registered: Jan 2008
Location: florida
Distribution: slackware64-current, puppy, ubuntu
Posts: 1,342

Rep: Reputation: 184Reputation: 184
Are you installing Gentoo or is this a running installation and is it 32bit or 64bit. If this an installation gone wrong, what is your host system 32bit or 64bit. I can some sort of duplicate the error the op is getting by using
Quote:
linux32 make menuconfig
and the
Quote:
make -j2
on a 64bit host machine. But not sure how this helps or will help someone else figure out what is wrong
 
Old 03-11-2012, 09:07 AM   #10
linux_sonic
Member
 
Registered: Nov 2009
Location: greece
Distribution: Gentoo, Backtrack
Posts: 50

Original Poster
Rep: Reputation: 1
Quote:
Originally Posted by colorpurple21859 View Post
what is in your /etc/make.conf
Here is my /etc/make.conf

Code:
# These settings were set by the catalyst build script that automatically
# built this stage.
# Please consult /usr/share/portage/config/make.conf.example for a more
#detailed example.
CFLAGS="-02 -march=i686 -pipe"
CXXFLAGS="${CFLAGS}"
# WARNING: Changing your CHOST is not something that should be done lightly.
# Please consult http://www.gentoo.org/doc/en/change-chost.xml before changing.
CHOST="i686-pc-linux-gnu"
 
Old 03-11-2012, 04:46 PM   #11
i92guboj
Gentoo support team
 
Registered: May 2008
Location: Lucena, Córdoba (Spain)
Distribution: Gentoo
Posts: 4,036

Rep: Reputation: 372Reputation: 372Reputation: 372Reputation: 372
But, as the output in your first post shows, your kernel sources are at least partly configured for x86_64. I already told you above the reasons why this can happen, and the procedures on how to fix this. You could also just try "make oldconfig". The script might or might not work depending on what the exact problem is. In any case, if it doesn, it will probably ask you a few things so it can configure your kernel properly.
 
Old 03-11-2012, 06:26 PM   #12
linux_sonic
Member
 
Registered: Nov 2009
Location: greece
Distribution: Gentoo, Backtrack
Posts: 50

Original Poster
Rep: Reputation: 1
Quote:
Originally Posted by i92guboj View Post
But, as the output in your first post shows, your kernel sources are at least partly configured for x86_64. I already told you above the reasons why this can happen, and the procedures on how to fix this. You could also just try "make oldconfig". The script might or might not work depending on what the exact problem is. In any case, if it doesn, it will probably ask you a few things so it can configure your kernel properly.
Hey look i am not good at linux
Could you tell me exactly what i have to do???
 
Old 03-12-2012, 12:02 PM   #13
i92guboj
Gentoo support team
 
Registered: May 2008
Location: Lucena, Córdoba (Spain)
Distribution: Gentoo
Posts: 4,036

Rep: Reputation: 372Reputation: 372Reputation: 372Reputation: 372
What did you do to configure your kernel?

Did you use genkernel as suggested in the handbook, or are you using some other method? Did you configure it by hand or did you copy it from some other installation? Is Gentoo already installed or are you still in the trance of installing it?

I really need some input to be able to help you.
 
Old 03-12-2012, 01:35 PM   #14
linux_sonic
Member
 
Registered: Nov 2009
Location: greece
Distribution: Gentoo, Backtrack
Posts: 50

Original Poster
Rep: Reputation: 1
Quote:
Originally Posted by i92guboj View Post
What did you do to configure your kernel?

Did you use genkernel as suggested in the handbook, or are you using some other method? Did you configure it by hand or did you copy it from some other installation? Is Gentoo already installed or are you still in the trance of installing it?

I really need some input to be able to help you.
I followed this steps http://www.gentoo.org/doc/en/gentoo-...ickinstall.xml
I cofigured the kernel by hand!!
I have downloaded this gentoo architecture amd64!!!
Is it the right achitecture for my cpu???
 
Old 03-13-2012, 10:05 AM   #15
i92guboj
Gentoo support team
 
Registered: May 2008
Location: Lucena, Córdoba (Spain)
Distribution: Gentoo
Posts: 4,036

Rep: Reputation: 372Reputation: 372Reputation: 372Reputation: 372
Quote:
Originally Posted by linux_sonic View Post
I followed this steps http://www.gentoo.org/doc/en/gentoo-...ickinstall.xml
I cofigured the kernel by hand!!
So, that means you used this:

Code:
make menuconfig
And you configured the kernel using the text based menus of menuconfig, right?

Quote:
I have downloaded this gentoo architecture amd64!!!
That architecture is ok for your cpu, as long as you want to use a 64 bits OS (you could also use the 32 bits version). In any case, the sources are exactly the same, no matter what architecture you are using. And the configure script should present you with the right options, so something is wrong with that.

What I'd do, is the following.

First, erase the whole kernel tree. If you did the chroot step, that should usually be /usr/src/linux.

Then, install the sources again. That'd be:

Code:
emerge gentoo-sources
Proceed again to configure your kernel from the ground using menuconfig, as per the guide you linked in your post above.
 
  


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
[SOLVED] lilo says my 2.6 kernel image is to large&new problem kernel will not boot smeezekitty Linux - Newbie 3 10-13-2009 08:41 PM
USB kernel problem installing Debian testing on HP Proliant ML310 G3 - kernel freeze sjust Linux - Hardware 11 01-27-2009 02:17 PM
compiling kernel problem --- Kernel panic: unable to mount root fs ........ anthonymts123 Linux - General 5 07-31-2006 02:29 AM
Linux Kernel Problem -- Kernel panic: CPU context corrupt crcooney Linux - Distributions 0 01-15-2004 08:48 AM


All times are GMT -5. The time now is 11:07 AM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration