Linux - NewbieThis 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
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I just attempted to upgrade my kernal from 2.4.22-1.2188 to 2.6.6. I followed all of the steps in this article from linuxquestions religiously:
Quote:
to install K2.6.5 to Fedora Core 1 you:
step one: get kernel from www.kernel.org
put in /home/((your name))/linux-2.6.?.tar.bz2
step two: open terminal window and type su then enter pasword.
step three: A: cd /usr/src
B: tar jxvf /home/((your name))/linux-2.6.?.tar.bz2
C: cd linux-2.6.?
D: type: make mrproper
E: cp /boot/config-2.4.22-1.2115.nptl .config
(( enter the kernel number you use for
step E:. look at boot up and write it down ))
step four: type: make menuconfig
(( now set up your kernel select processor type,
sound,and what ever else you would like in
your new kernel))
step five: exit and save changes
step six :
type: make bzImage && make modules modules_install
next
type: make install
I have the functional kernal 2.6.6, but without the 2.6.6-1.xxxx.nptl file in my /boot/ directory, I can't get things to work. I think where I had the problem was in the poster's step E. I did a cp on the latest .nptl file I had, which was 2.4.22-1.2188, but I don't see the .config file anywhere in the /boot/ directory.
Grub sees the 2.6.6 kernel, but when I try to boot into it, it doesn't see any of my hardware (mouse, network card). I am posting this by booting into the old 2.4.22-1.2188 kernel, but I would like to know how to get the new .nptl file created. Like I said, I did every one of the steps that the poster above called for. If you want to see the entire thread that I found that info in, it can be found here .
to be honest (hoping im not insultng any1 reading this)
thats a pretty crappy method.
the difference between 2,4 and 2,6 kernels is insane !!!!
also.. he forgot to mention that you must select "load configureation from external file"
once in the make menuconfig and select the kernel you renamed for no aparent reason.
you would get a far better kernel if you did it properly.
So you suggest I ditch the previous attempt and build a new kernel from scratch?
I'm fine with that, it is a good learning experience and I have the time to do it. The only problem I have with it is that everywhere I look, I find different instructions on how to upgrade the kernel. Do you suggest I follow the documantation that came with the source from kernel.org, or is there a site that has worthwile directions on compiling a new kernel?
there are many different ways to do the same thing.
however, the ONLY way oto get a good kernel. is to configure it yourself.
or atleast use a config file was was designed for that exact kernel.
anyways... here's the general way.
make xconfig (or make gconfig or make menuconfig or make config)
config is command line... nasty.
xconfig is graphical, but has dependency's you may not have
gconfig is graphical with different dependency's u may not have
menuconfig is non graphical. but stil has a good interface, i would recomend this.
if you want to use a anouther config file (like it says in the guide you posted, then use one)
BUT... and this is a MUST !
go through EVERY option. read every option, read every description of every option (by selecting help)
NEVER EVER EVER guess the answer to a question, if you dont know, then look it up !
answers to questions about your processor can be found by giving the command
"cat /proc/cpuinfo"
or, if you get a question like..... "Support msr" look for anything to do with msr in the output.... (in this case, msr is listed in the cpu flags for my processor (Athlon))
Usually questions on drivers can be found by running the command "cat /proc/pci"
it tells you the name of the chipset that controll everything connected to your pci bus.
When ever possible... it is usually best to compile somthing as a Module (M)
if you make a mistake, and compile somthing you shoudnt have, if you compiled it as a module, you can simply remove it. if you compile into the kernel, its there to stay.
dont compile drivers you dont need.
when you are happy with your config, save it... (also save it to your home directory as a backup)
then make bzImage
make modules
make modules_install
make install
ALSO... i find with some distro's you need to edit the /boot/grub/grub.conf file.
often, the kernel will have a parameter like this
1 thing still hasn't been answered for me though - the original question of my post. What generates the .nptl file? I have 3 .nptl files in my /boot/ directory, corresponding to the 3 versions of the kernel that I've had in Fedora Core 1. Following the shortcut kernel that was made by following the other guy's steps one wasn't generated, and I see although I'll be more specific going step by step, I'm doing the same type things, make menuconfig, make bzImage etc.
Will going through more carfully generate a config-2.6.6-1.000.nptl? Do I simply copy one of the files aready there and rename it?
Thanks again for the help, I'd be lost without this site!
after you have configured your kernel with make menuconfig (or whatever) select save.
then save a backup. i usually put it in my home directory so i remember to back it up when i format.
bt you could save it as /boot/config-kernel-version if you want. the file is not an ntpl file... its a kernel config file. i think that ntpl are the initials of some kernel patches fedora apply to 2.4 kernels.
Ok, it could be that the .ntpl files are just mods done to the kernel by Fedora.
I used make gconfig, because it gave me much info about the choices.
The only problem I had found with my initial 2.6.6 kernel was that it didn't support my network card, cound card, and usb mouse. I think I have corrected at least some of those issues through gconfig, but now I hit a new stumbling block.
[root@jimb linux-2.6.6]# make bzImage
make[1]: `arch/i386/kernel/asm-offsets.s' is up to date.
CHK include/linux/compile.h
CC kernel/printk.o
kernel/printk.c:82: error: `null' undeclared here (not in a function)
kernel/printk.c:84: error: `null' undeclared here (not in a function)
kernel/printk.c: In function `log_buf_len_setup':
kernel/printk.c:212: error: `null' undeclared (first use in this function)
kernel/printk.c:212: error: (Each undeclared identifier is reported only once
kernel/printk.c:212: error: for each function it appears in.)
kernel/printk.c: At top level:
kernel/printk.c:82: error: storage size of `__log_buf' isn't known
kernel/printk.c:82: warning: `__log_buf' defined but not used
make[1]: *** [kernel/printk.o] Error 1
make: *** [kernel] Error 2
I thought this might be because I pulled all support for a printer out of my kernel, but after I read the file /usr/src/linux-2.6.6/kernel/printk.c I found nothing about a printer. Anyone have ideas on how to avoid those errors - they are blocking the make bzImage command, and I can't proceed without that working.
Ok, it could be that the .ntpl files are just mods done to the kernel by Fedora.
the Config-xxxxx.ntpl file IS the defaults fedora kernel configureation.
they put it there incase you need to know what options your running kernel was compiled with..
for example... is jfs supported ? if so is it built in, or do i need to modprobe.
that kind of thing.
unless you use it as a template to build your new config, or you read it, it use useless.
the system does not use it. it is for your benefit only.
anyways, yeah, looks like you picked some conflicting kernel options.
find out what part of the kkernel that source if used for and sort it out.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.