Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
where is the kernel image?
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Installing Gentoo
View previous topic :: View next topic  
Author Message
kramdolf
n00b
n00b


Joined: 24 Mar 2010
Posts: 47

PostPosted: Mon Apr 25, 2011 12:23 am    Post subject: where is the kernel image? Reply with quote

Hello,
I have a question, I am installing Gentoo and compiled a kernel for x86 and did

"make && make modules_install" and it compiled successfully.

then when I try to copy the kernel to its place:

"cp arch/i386/boot/bzImage /boot/kernel-2.6.34-gentoo-r1"

it cant find the arch/i386 directory, so I cant place the kernel :(

the /boot dir it finds though.

Please help me, thx
Back to top
View user's profile Send private message
keet
Guru
Guru


Joined: 09 Sep 2008
Posts: 574

PostPosted: Mon Apr 25, 2011 12:43 am    Post subject: Reply with quote

Is it in /usr/src/linux/arch/x86/boot?
Back to top
View user's profile Send private message
kramdolf
n00b
n00b


Joined: 24 Mar 2010
Posts: 47

PostPosted: Mon Apr 25, 2011 12:57 am    Post subject: Reply with quote

The directory /usr/src/linux/arch/x86/boot exist but there is no "bzImage" or kernel there as far as I can tell. (Unless its the dir thing called "compressed" with blue text)


Any other idea? I am excited since I almost have a working gentoo system :) But it surely needs a kernel.
Back to top
View user's profile Send private message
Jaglover
Watchman
Watchman


Joined: 29 May 2005
Posts: 8291
Location: Saint Amant, Acadiana

PostPosted: Mon Apr 25, 2011 1:04 am    Post subject: Reply with quote

Try arch/i386/boot/bzImage
_________________
My Gentoo installation notes.
Please learn how to denote units correctly!
Back to top
View user's profile Send private message
kramdolf
n00b
n00b


Joined: 24 Mar 2010
Posts: 47

PostPosted: Mon Apr 25, 2011 1:08 am    Post subject: Reply with quote

I tried "cd arch" and "cd /arch" it says "No such file or directory"
Back to top
View user's profile Send private message
DONAHUE
Watchman
Watchman


Joined: 09 Dec 2006
Posts: 7651
Location: Goose Creek SC

PostPosted: Mon Apr 25, 2011 2:43 am    Post subject: Reply with quote

be sure you are in the chroot
Code:
find  / -name bzImage
Takes a while. Post the result.

Quote:
"cp arch/i386/boot/bzImage /boot/kernel-2.6.34-gentoo-r1"
why such an old and obsolete kernel? It will have a hard time with a current system.

correct typo
_________________
Defund the FCC.


Last edited by DONAHUE on Mon Apr 25, 2011 2:26 pm; edited 1 time in total
Back to top
View user's profile Send private message
krinn
Watchman
Watchman


Joined: 02 May 2003
Posts: 7471

PostPosted: Mon Apr 25, 2011 2:43 am    Post subject: Reply with quote

make install

now it is under /boot/vmlinuz + /boot/vmlinuz-kernelversion
Back to top
View user's profile Send private message
kramdolf
n00b
n00b


Joined: 24 Mar 2010
Posts: 47

PostPosted: Mon Apr 25, 2011 11:42 am    Post subject: Reply with quote

I was in chroot, "find -name / bzImage" or "find -name bzImage" doesn't work for me.

I tried "make install" nothing happened.

the "arch/i386/boot..." line I just copied from the handbook but I assumed a newer kernel
would be in "arch" folder aswell, since it was in the docs.

Any other ideas?
Back to top
View user's profile Send private message
Jaglover
Watchman
Watchman


Joined: 29 May 2005
Posts: 8291
Location: Saint Amant, Acadiana

PostPosted: Mon Apr 25, 2011 12:03 pm    Post subject: Reply with quote

arch/i386/boot/bzImage is the correct location for a 32-bit kernel. If it's not there then you probably weren't chrooted properly when you ran make.

Did you try make install as krinn suggested?
_________________
My Gentoo installation notes.
Please learn how to denote units correctly!
Back to top
View user's profile Send private message
kramdolf
n00b
n00b


Joined: 24 Mar 2010
Posts: 47

PostPosted: Mon Apr 25, 2011 12:17 pm    Post subject: Reply with quote

I tried "make install"
it said: "make **' No rule to make target ìnstall´. Stop."

I'm not so experienced with Linux and Gentoo so I might miss something simple.

I have /mnt/gentoo and /mnt/gentoo/boot on the same harddrive without partitions
Maybe I somehow missed to create a simpe "/" root partition?

Thanks for the help


(addition:)
I did some other things efter compiling the kernel even though it wasn't in place, for example emerging a system logger and xorg, while I slept.
Back to top
View user's profile Send private message
kramdolf
n00b
n00b


Joined: 24 Mar 2010
Posts: 47

PostPosted: Mon Apr 25, 2011 1:08 pm    Post subject: Reply with quote

I found this with google:

> On Friday 15 September 2006 18:53, Steven G Wagner wrote:
>
>> I'm trying to install a 2.6.16-hardened-r11 kernel and I keep getting this
>> error:
>>
>> cp: cannot stat 'arch/i386/kernel/bzImage': No such file or directory
>>
>
> If at that moment you typed pwd you would see that you were not in
> the /usr/src/linux directory and therefore the path to
> arch/i386/kernel/bzImage could not be found. Go back into /usr/src/linux
> before you run again the cp command:
>
> cd /usr/src/linux
> cp arch/i386/kernel/bzImage /boot/'whatever_you_want_to_call_it'
>

Also my kernel isn´t in arch/i386/kernel/bzImage but in
arch/i386/boot/bzImage.

solved it I think :)
Back to top
View user's profile Send private message
kramdolf
n00b
n00b


Joined: 24 Mar 2010
Posts: 47

PostPosted: Mon Apr 25, 2011 1:20 pm    Post subject: Reply with quote

I went here cd /usr/src/linux

and then "cp arch/i386/boot/bzImage /boot/kernel-2.6-gentoo-r1"
it seemed to copy correctly, but
when I wrote the lilo conf file and then "/sbin/lilo":

it responded with "Fatal: open /boot/kernel-2.6-gentoo-r1: No such file or directoy"

Any ideas what to do?
Back to top
View user's profile Send private message
champ
Tux's lil' helper
Tux's lil' helper


Joined: 25 Oct 2006
Posts: 97
Location: Thailand

PostPosted: Mon Apr 25, 2011 1:32 pm    Post subject: Reply with quote

Did you do "mount /boot" before copying?
_________________
"Those who would give up Essential Liberty to purchase a little Temporary Safety, deserve neither Liberty nor Safety." - Benjamin Franklin

blog: johnsearth.blogspot.com
Back to top
View user's profile Send private message
kramdolf
n00b
n00b


Joined: 24 Mar 2010
Posts: 47

PostPosted: Mon Apr 25, 2011 1:44 pm    Post subject: Reply with quote

/boot is mounted.

But now I cant copy the bzImage.

"I went here cd /usr/src/linux

and then "cp arch/i386/boot/bzImage /boot/kernel-2.6-gentoo-r1 " now that doesn't work it says "No such file or directory"
Back to top
View user's profile Send private message
DONAHUE
Watchman
Watchman


Joined: 09 Dec 2006
Posts: 7651
Location: Goose Creek SC

PostPosted: Mon Apr 25, 2011 4:11 pm    Post subject: Reply with quote

Quote:
I have /mnt/gentoo and /mnt/gentoo/boot on the same harddrive without partitions
Maybe I somehow missed to create a simpe "/" root partition?
Is confusing. Could you boot the cd and run and post the results of
Code:
fdisk -l
Then mount the gentoo partition(s) and run and post the results of
Code:
df -h

Apologies for mistyping earlier, should have been
Code:
find / -name bzImage

_________________
Defund the FCC.
Back to top
View user's profile Send private message
gerard27
Advocate
Advocate


Joined: 04 Jan 2004
Posts: 2377
Location: Netherlands

PostPosted: Mon Apr 25, 2011 4:44 pm    Post subject: Reply with quote

When you are in /usr/src/linux directory the correct way to issue the cp command would be like this
Code:

cp ./arch/i386/boot/bzImage /boot/kernel-2.6-gentoo-r1

Notice the dot and slash.
Gerard.
_________________
To install Gentoo I use sysrescuecd.Based on Gentoo,has firefox to browse Gentoo docs and mc to browse (and edit) files.
The same disk can be used for 32 and 64 bit installs.
You can follow the Handbook verbatim.
http://www.sysresccd.org/Download
Back to top
View user's profile Send private message
kramdolf
n00b
n00b


Joined: 24 Mar 2010
Posts: 47

PostPosted: Mon Apr 25, 2011 6:55 pm    Post subject: Reply with quote

I think I made a mistake during file and partitioning setup.

When I entered "find / -name bzImage" it says:

File system loop detected: /boot is part of the same file system loop as /.

This is the problem I think. I used gparted on the live dvd to just format both harddrives to ext3 primary, without sections or partitions. And made sda1 into /mnt/gentoo AND /mnt/gentoo/boot

Can I fix this somehow and keep what I already have emerged and the system files I edited?

Thanks for the help
Back to top
View user's profile Send private message
DONAHUE
Watchman
Watchman


Joined: 09 Dec 2006
Posts: 7651
Location: Goose Creek SC

PostPosted: Mon Apr 25, 2011 7:12 pm    Post subject: Reply with quote

yes probably
boot cd
mount /dev/sda1 /mnt/gentoo
do not mount /mnt/gentoo/boot
I am presuming sda1 if different ...
Code:
cd /mnt/gentoo
find /mnt/gentoo -name bzImage
ls -l
should give clues as to system health
if you have a /boot line in /mnt/gentoo/etc/fstab delete it
If all looks good continue into the chroot:
Code:
mount -t proc none /mnt/gentoo/proc
mount -o bind /dev /mnt/gentoo/dev
chroot /mnt/gentoo /bin/bash
env-update
source /etc/profile
export PS1="(chroot) $PS1"
cd /usr/src/linux
make menuconfig
check the menuconfig
Code:
make && make modules_install
cp arch/i386/boot/bzImage /boot/<your kernel name-can be anything>
finish the handbook to first reboot
_________________
Defund the FCC.


Last edited by DONAHUE on Mon Apr 25, 2011 7:21 pm; edited 1 time in total
Back to top
View user's profile Send private message
gerard27
Advocate
Advocate


Joined: 04 Jan 2004
Posts: 2377
Location: Netherlands

PostPosted: Mon Apr 25, 2011 7:17 pm    Post subject: Reply with quote

It's not clear to me what exactly you did.
What do you have on disk 1 and what on disk 2?
Gerard.
_________________
To install Gentoo I use sysrescuecd.Based on Gentoo,has firefox to browse Gentoo docs and mc to browse (and edit) files.
The same disk can be used for 32 and 64 bit installs.
You can follow the Handbook verbatim.
http://www.sysresccd.org/Download
Back to top
View user's profile Send private message
DONAHUE
Watchman
Watchman


Joined: 09 Dec 2006
Posts: 7651
Location: Goose Creek SC

PostPosted: Mon Apr 25, 2011 7:27 pm    Post subject: Reply with quote

@ kramdolf
Mon Apr 25, 2011 2:12 pm Post should answer your question

@gerard
he ran:
Code:
mount /dev/sda1 /mnt/gentoo
mkdir /mnt/gentoo/boot
mount /dev/sda1 /mnt/gentoo/boot

where the handbook says:
Quote:
Code Listing 5.1: Mounting partitions
# mount /dev/sda3 /mnt/gentoo
# mkdir /mnt/gentoo/boot
# mount /dev/sda1 /mnt/gentoo/boot
Not the first, won't be the last

meaning of disk1 and disk2 is a good question
posting
Code:
fdisk -l
would be a good answer
_________________
Defund the FCC.
Back to top
View user's profile Send private message
aidanjt
Veteran
Veteran


Joined: 20 Feb 2005
Posts: 1118
Location: Rep. of Ireland

PostPosted: Mon Apr 25, 2011 10:40 pm    Post subject: Reply with quote

I just run `make install`, and it copies it over as /boot/vmlinuz-{version} and automatically updates kernel image symlinks if they already exist. I don't know why the handbook recommends a manual copy, don't really care, either. The install target works just fine.
_________________
juniper wrote:
you experience political reality dilation when travelling at american political speeds. it's in einstein's formulas. it's not their fault.
Back to top
View user's profile Send private message
nemectic
Apprentice
Apprentice


Joined: 20 Aug 2004
Posts: 182

PostPosted: Mon Apr 25, 2011 10:42 pm    Post subject: Reply with quote

I prefer copying them over myself, and having a meaningful name. If you have several vmlinuz-xxxx, it can get a little confusing if you don't keep track of them - I'm guessing whoever wrote the handbook thought the same.
Back to top
View user's profile Send private message
aidanjt
Veteran
Veteran


Joined: 20 Feb 2005
Posts: 1118
Location: Rep. of Ireland

PostPosted: Mon Apr 25, 2011 10:45 pm    Post subject: Reply with quote

Yeah, perhaps. Works for me, though. :)
_________________
juniper wrote:
you experience political reality dilation when travelling at american political speeds. it's in einstein's formulas. it's not their fault.
Back to top
View user's profile Send private message
nemectic
Apprentice
Apprentice


Joined: 20 Aug 2004
Posts: 182

PostPosted: Mon Apr 25, 2011 10:57 pm    Post subject: Reply with quote

Yeah, I think it's just a matter of taste. Gentoo, and Linux in general, is all about choice after all. :)
Back to top
View user's profile Send private message
kramdolf
n00b
n00b


Joined: 24 Mar 2010
Posts: 47

PostPosted: Tue Apr 26, 2011 12:45 pm    Post subject: Reply with quote

Thank you for your helpful responses
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Installing Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum