LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 05-11-2004, 06:57 PM   #256
DrOzz
Senior Member
 
Registered: May 2003
Location: Sydney, Nova Scotia, Canada
Distribution: slackware
Posts: 4,185

Original Poster
Rep: Reputation: 60

one thing i want you to make sure of before this discussion continues is that you have
exact architecture of your cpu selected in the kernel config ... this could easily cause
issues like your having causing an incomplete boot ... and not only that, just go back
to the kernel config and make sure anything else that is incorrect is indeed corrected ..
 
Old 05-12-2004, 09:49 PM   #257
DaOne
Member
 
Registered: Jan 2003
Location: USA
Distribution: Slackware
Posts: 498

Rep: Reputation: 30
DrOzz...excellent guide!
 
Old 05-13-2004, 07:04 AM   #258
3dmike
LQ Newbie
 
Registered: Mar 2004
Location: Out on a limb...
Distribution: SuSE 9.0
Posts: 21

Rep: Reputation: 15
Excellent guide!

I'm trying to upgrade from Kernel 2.4 to 2.6.6 and your guide has been very clear and helpful, but I have one problem right at the end of the procedure...

I have removed the old initrd.img as you instruct, but dont seem to be able to create the new one. The command I use is /sbin/mkinitrd /boot/initrd-2.6.6.img 2.6.6

The output I get back is...
/boot/initrd-2.6.6.img/var/tmp is not a directory

I'm sure this sounds really simple and I'm just doing something very basic wrong, at least I hope so. Please help me finish the kernel patch!

Regards,
Mike
 
Old 05-13-2004, 09:20 PM   #259
DrOzz
Senior Member
 
Registered: May 2003
Location: Sydney, Nova Scotia, Canada
Distribution: slackware
Posts: 4,185

Original Poster
Rep: Reputation: 60
two key things i noticed in your post 3dmike ...
first you mention about the upgrade from 2.4 to 2.6, so my question is did
you upgrade modutils (refer to first to links in guide if not)
and secondly, are you say "patch the kernel" are you actually trying to use
a patch from 2.4 to 2.6 or was that just your terminoligy in your post ?

and thanks DaOne, you have a great guide (2 guides) yourself
 
Old 05-16-2004, 07:19 AM   #260
alaios
Senior Member
 
Registered: Jan 2003
Location: Aachen
Distribution: Opensuse 11.2 (nice and steady)
Posts: 2,203

Rep: Reputation: 45
make clean

Hi i want to know why we must execute the make dep before the make clean command.... If i execute firstly the make clean?
 
Old 05-16-2004, 12:26 PM   #261
DrOzz
Senior Member
 
Registered: May 2003
Location: Sydney, Nova Scotia, Canada
Distribution: slackware
Posts: 4,185

Original Poster
Rep: Reputation: 60
keyword underneath "make dep" is ensures the includes are in place ... it does a
check, make clean is going to do exactly what it says, clean the source for you don't
have any issues... this does not say it is going to remove the include files ..
 
Old 05-17-2004, 01:28 PM   #262
analyst
LQ Newbie
 
Registered: Apr 2004
Posts: 2

Rep: Reputation: 0
Hello everybody down there.

I am trying to move from 2.4.18 to 2.4.26 ( not patching). I did almost everything as in the guide(some minor differences though), but still i can't load my new Kernel. the loading stops with the kernel panic

VFS: cannot load root fs on 00:00

help!(i am reslly desperate)
 
Old 05-17-2004, 03:39 PM   #263
SteveK1979
Member
 
Registered: Feb 2004
Location: UK
Distribution: RHEL, Ubuntu, Solaris 11, NetBSD, OpenBSD
Posts: 225

Rep: Reputation: 43
Lightbulb

Hi,

Just a quick post in reply to 3dmike I had the same problem with SuSE9.0 when trying to compile a new kernel, and if you read through this thread, you should find that I think it was Garp got it figured out! Page 16 of this thread I think...

I never actually tried it out, as (with a little prompting from DrOzz cheers) I switched to Slack 9.1 and haven't really looked back since....

Cheers,

Steve
 
Old 05-17-2004, 04:15 PM   #264
DrOzz
Senior Member
 
Registered: May 2003
Location: Sydney, Nova Scotia, Canada
Distribution: slackware
Posts: 4,185

Original Poster
Rep: Reputation: 60
analyst can you tell us what distro your using, and what are these minor differences
and also if you can supply a little more of that error that would be great also ....
maybe like 3 - 5 lines that appear before that message ... thx !
 
Old 05-18-2004, 01:57 AM   #265
analyst
LQ Newbie
 
Registered: Apr 2004
Posts: 2

Rep: Reputation: 0
I am using the redHat 8.0. The minor differences are that i didn't overwrite the old kernel( the old vmlinuz and initrd are still there and active(so that i can post right now), and some naming differences( i didnt' rename bzImage into vmlinuz).

when i try to ryn my new kernel, it does everything well until the VFS part.then it stops with an error message

VFS:cannot open root device "LABEL=/" or 00:00
Please append a correct "root=" boot option
kernel panic: VFS: Unable to mount root fs on 00:00

this is my grub.conf

# grub.conf generated by anaconda
#
# Note that you do not have to rerun grub after making changes to this file
# NOTICE: You have a /boot partition. This means that
# all kernel and initrd paths are relative to /boot/, eg.
# root (hd0,0)
# kernel /vmlinuz-version ro root=/dev/hdd5
# initrd /initrd-version.img
#boot=/dev/hdc
default=0
timeout=10
splashimage=(hd0,0)/grub/splash.xpm.gz
title Red Hat Linux (2.4.18-14)
root (hd0,0)
kernel /vmlinuz-2.4.18-14 ro root=LABEL=/ hdb=ide-scsi
initrd /initrd-2.4.18-14.img
title test kernel (2.4.26)
root (hd0,0)
kernel /bzimage-2.4.26 ro root=LABEL=/ hdb=ide-scsi
initrd /initrd-2.4.26.img
 
Old 05-18-2004, 08:36 AM   #266
iZvi
Member
 
Registered: Mar 2004
Location: Valhalla
Distribution: Slackware-current, kernel 2.6.31
Posts: 284

Rep: Reputation: 35
Hi, I want to compile 2.6.6 kernel. However I'm not sure what version of gcc I should use. Also I tried make menuconfig, but it gives me the following errors:

bash-2.05b# make menuconfig
HOSTCC scripts/basic/fixdep
In file included from /usr/include/bits/posix1_lim.h:126,
from /usr/include/limits.h:144,
from /usr/lib/gcc-lib/i486-slackware-linux/3.3.3/include/limits
.h:122,
from /usr/lib/gcc-lib/i486-slackware-linux/3.3.3/include/syslim
its.h:7,
from /usr/lib/gcc-lib/i486-slackware-linux/3.3.3/include/limits
.h:11,
from scripts/basic/fixdep.c:105:
/usr/include/bits/local_lim.h:36:26: linux/limits.h: No such file or directory
In file included from /usr/include/netinet/in.h:212,
from scripts/basic/fixdep.c:107:
/usr/include/bits/socket.h:305:24: asm/socket.h: No such file or directory
scripts/basic/fixdep.c: In function `use_config':
scripts/basic/fixdep.c:193: error: `PATH_MAX' undeclared (first use in this func
tion)
scripts/basic/fixdep.c:193: error: (Each undeclared identifier is reported only
once
scripts/basic/fixdep.c:193: error: for each function it appears in.)
scripts/basic/fixdep.c:193: warning: unused variable `s'
scripts/basic/fixdep.c: In function `parse_dep_file':
scripts/basic/fixdep.c:289: error: `PATH_MAX' undeclared (first use in this func
tion)
scripts/basic/fixdep.c:289: warning: unused variable `s'
make[1]: *** [scripts/basic/fixdep] Error 1
make: *** [scripts_basic] Error 2

I'm sure I'm missing something, but it's difficult to find out what exactly. Can it be wrong version of something or something is missing?
 
Old 05-21-2004, 02:06 PM   #267
PGDubbin
Member
 
Registered: May 2004
Location: NJ - USA
Distribution: Gentoo on 2.6.6
Posts: 39

Rep: Reputation: 15
I remember when I first learned how to do the kernel

I did it with a buddy of mine and we wound up with an image size of 1.7MB. A month later, I took another stab at it and dropped the kernel size down to 1.1MB and with all my normal apps running, (Opera, xmms, gaim, fluxbox) I sit at about 5% CPU usage and 70mb of ram (5% of 550mhz)
 
Old 05-23-2004, 04:53 AM   #268
heretic
LQ Newbie
 
Registered: Jun 2003
Location: Albuq, NM
Distribution: Mandrake & Slackware
Posts: 11

Rep: Reputation: 0
Drozz, U da man!

That guide really helped me through some of the rough spots, man.

And I'VE successfully compiled lots of the old kernels (2.2 & 2.4)
before, so I was somewhat mystified.

But your little run-through cleared things right up.

Hope you get to see this reply.
Much thanks!

heretic
 
Old 05-23-2004, 05:11 AM   #269
Duukkis
Member
 
Registered: May 2003
Location: Finland
Distribution: Debian Sarge
Posts: 75

Rep: Reputation: 15
I did a big mistake when I tried to do a grub floppy disk. Because I was compiling the new kernel 2.6.6 I decided to post there. I did the following command:

debianmasiina:/# grub-floppy /dev/hde1
You are about to overwrite the boot sector of the following device:
/dev/hde1
Are you sure you want to take this action (y/N) y
Creating grub boot floppy now, please be patient ...

1+0 records in
1+0 records out
512 bytes transferred in 0.018241 seconds (28069 bytes/sec)
202+1 records in
202+1 records out
103592 bytes transferred in 0.055991 seconds (1850151 bytes/sec)

That's All Folks!

Now all files in /boot are corrupted or something because there isn't menu.lst file in /boot/grub anymore:

debianmasiina:/boot/grub# ls -la
ls: cannot read symbolic link stage1: Input/output error
ls: jfs_stage1_5: Input/output error
ls: menu.lst: Input/output error
ls: menu.lst~: Input/output error
total 10062961254
drwxr-xr-x 2 root root 1024 May 23 12:25 .
drwxr-xr-x 4 root root 1024 May 23 12:18 ..
drwxr-xr-x 4 root root 1024 May 23 12:18 device.map
?--x-wS-wT 29696 2339636158 704970620 19458177 Dec 22 1977 e2fs_stage1_5
?r-S--Sr-T 3180 904432387 3187706577 1160315973 Sep 10 2010 fat_stage1_5
?r-S-----T 109 19710 28517 1768186223 Feb 4 1970 ffs_stage1_5
?-wxr-x-w- 29807 1740636290 2305191778 33751040 Jul 22 1994 minix_stage1_5
b-----S--T 43199 3677483197 365756416 243, 252 Jul 11 1980 reiserfs_stage1_5
lr-xr--rw- 17467 1207860292 1431440452 1725051238 May 15 1972 stage1
br-sr-Sr-t 443 109 114 0, 0 Jan 6 1987 stage2
?-wSrws--T 65433 41300307 1183574293 16890331 Jan 2 1970 vstafs_stage1_5
c--Srwsr-T 1148 64372 61500 236, 60 May 21 1972 xfs_stage1_5

I installed lilo because grub is mixed up, but I get some errors:

Setting up lilo (22.5.9-2) ...
ln: creating symbolic link `/boot/debianlilo.bmp' to `/usr/share/lilo/contrib/debianlilo.bmp': Input/output error
cp: cannot create regular file `/boot/debianlilo.bmp': Input/output error
ln: creating symbolic link `/boot/sarge.bmp' to `/usr/share/lilo/contrib/sarge.bmp': Input/output error
cp: cannot create regular file `/boot/sarge.bmp': Input/output error
ln: creating symbolic link `/boot/sid.bmp' to `/usr/share/lilo/contrib/sid.bmp': Input/output error
cp: cannot create regular file `/boot/sid.bmp': Input/output error

I think I should have made "grub-floppy /dev/fd0" to make a boot a floppy. Now /dev/hde1 is also mixed up:

temonen@debianmasiina:/boot$ df -h
Filesystem Size Used Avail Use% Mounted on
/dev/hde2 4.6G 129M 4.3G 3% /
tmpfs 253M 0 253M 0% /dev/shm
/dev/hde1 3.3T 3.3T 0 100% /boot
/dev/hde5 9.2G 1.7G 7.1G 19% /usr
/dev/hde6 19G 4.1G 14G 24% /opt
/dev/hde7 7.4G 417M 6.6G 6% /var
/dev/hde8 7.4G 33M 7.0G 1% /tmp
/dev/hde9 100G 3.7G 92G 4% /home
/dev/fd0 1.4M 810K 530K 61% /floppy

I backed up the files in /boot which are still non-corrupted and now they are in / (dev/hde2). I need help really quickly because I cannot configure my bootloader in /boot and I'm not sure if my old kernel's boot disk works !!!

Last edited by Duukkis; 05-23-2004 at 05:41 AM.
 
Old 05-25-2004, 02:44 PM   #270
alaios
Senior Member
 
Registered: Jan 2003
Location: Aachen
Distribution: Opensuse 11.2 (nice and steady)
Posts: 2,203

Rep: Reputation: 45
cant find mkinitrd

Hi i have followed all the steps found here.... I can't find the mkinitrd command... I have tried the locate command... I have tried also an extensive search...but mkinitrd is nowhere...
I am using the latest version of slackware...... with lilo.....

Also how i can put a default value in my boot loader.. I want top boot the seconf os by default...and h ow i can add it?
Thx
 
  


Reply



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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
I'm interested in compiling a 2.6.x kernel, is this is a decent guide? Erik_the_Red Linux - Newbie 7 08-14-2005 06:03 AM
Kernel compiling guide for newbies... DaOne Slackware 127 04-17-2005 04:20 AM
Acid Guide to compiling Kernel 2.6.10 on Slack 10.1 acidjuice Slackware 54 03-11-2005 05:16 PM
Quick newbie guide to rebuild kernel in FC3 borgware Fedora 0 12-29-2004 01:38 PM
: Kernel compiling guide for newbies Question Anibal Slackware 6 08-01-2003 07:06 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 06:12 AM.

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
Open Source Consulting | Domain Registration