Welcome to the most active Linux Forum on the web.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
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!


  Search this Thread
Old 05-01-2006, 04:24 PM   #1
LQ Newbie
Registered: May 2006
Location: Poland
Distribution: Fedora Core 4
Posts: 3

Rep: Reputation: 0
updating kernel using yum and compiling it`s sources

Hello There
I am wondering what`s the difference between compiling linux kernel from sources and downloading rpm package (eg via yum). I`ve done such an operation today. After having 'yum update' finished, I had two kernels installed on my system: the old one and the new version. Also a new option was added to my bootloader allowing to choose a new version of kernel to boot. Everything seems to work just fine. So here is my queston: Is the effect of updating kernel via yum exactly the same as the one after compiling and installing the sources?

I`m gratefull for your time

Last edited by Ruald; 05-01-2006 at 05:36 PM.
Old 05-01-2006, 04:56 PM   #2
Senior Member
Registered: Dec 2005
Location: United Kingdom
Distribution: Fedora , Ubuntu, Slackware-Current
Posts: 1,526

Rep: Reputation: 53

Welcome to LQ! In answer to your question, when you install a new kernel via yum, you are installing the rpm binaries already pre-configured. When you download a source kernel and compile it yourself, you must configure the kernel yourself, adding options that you want and deleting ones you don't.

I have had good experiences in Fedora both ways. However, I have had some difficulties using both ways as well. When you install a pre-configured kernel, you have no control how it is congured unless you recompile it yourself. Also, preconfigured kernels can wreak havok with some software which depends on a certain kernel version.

Either way, when you install a new kernel, you must reinstall some software as well, particularly nVidia drivers as they are kernel specific.

It does no harm to have more than one kernel installed, and it is wise to have one known bootable kernel in case something goes wrong with a new kernel install.

Hope this helps,

Old 05-01-2006, 05:04 PM   #3
David the H.
Bash Guru
Registered: Jun 2004
Location: Osaka, Japan
Distribution: Arch + Xfce
Posts: 6,852

Rep: Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037
You basically have two options when it comes to the kernel, or any software really. Either you can compile it yourself from source, or you can use a precompiled (packaged) version.

A precompiled kernel is the easy way to go about it. Everything has already been done for you and all you have to do is install it. But a precompiled kernel is a generic kernel. The people who made it had to configure it to run a variety of hardware/software combinations. Such a kernel will thus generally be a bit larger and slower than one you make yourself.

Compiling from source, OTOH, gives you better performance generally, as your kernel will end up being configured perfectly for your system. You can choose to leave out anything you don't need, or add anything you do. You can also compile in support for hardware or other settings that the generic kernel might not supply.

For example, I just finished compiling a new kernel myself. Since I often need to share files with Japanese Windows computers, I chose to compile in in support for FAT filesystems with Japanese character encodings. Now whenever I mount a FAT disk with Japanese filenames, they automatically appear correctly (It's possible to do this with mount command options, but since I encounter it often, it's much more convenient to have it in the kernel). Prepackaged kernels will almost never have something like that.

OTOH, compiling things yourself is generally more difficult to do. You have to understand the settings options and possible problems you will encounter. Library dependencies are a big headache, for example. With a kernel, there are literally hundreds of options, and very little guidance about what they all do. You can very easily compile an unusable kernel. But mostly it's just a learning curve. Once you become experienced at it, it gets much easier.

So the short form is, easy but generic, or complicated but optimized. It's your choice.
The same is true of any program out there.
I hope this clears it up for you.

PS: If YUM is anything like Debian, there might be source packages as well as kernel packages. Whereas the kernel packages will install a working kernel onto your system, a source package just gives you, well, the source for the kernel. You'll still have to compile an actual kernel yourself from those files.
Old 05-01-2006, 05:22 PM   #4
LQ Newbie
Registered: May 2006
Location: Poland
Distribution: Fedora Core 4
Posts: 3

Original Poster
Rep: Reputation: 0
Originally Posted by BobNutfield
when you install a new kernel, you must reinstall some software as well
Thats right. I had to reinstall a module which handles ntfs partition so that it`s verion is suitable for new kernel.

Thanks both of you. Now things are getting clear for me. The next step will be "compiling kernel and understanding compilation parameters" i guess


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
compiling kernel sources joshknape Mandriva 17 09-16-2005 08:33 PM
Compiling kernel from vanilla sources - suse 9.2 lukas_svoboda SUSE / openSUSE 11 03-26-2005 07:18 AM
Problem Updating lilo after compiling kernel..... mir_sheely Linux - Software 10 07-19-2004 05:59 AM
How many diff methods of Installing, Compiling Kernel Sources are there? DriveMeCrazy Red Hat 6 05-10-2004 02:53 PM
Updating the Sources Database?? fdiaz05 Linux - Software 0 02-18-2003 12:00 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 09:55 AM.

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