SlackwareThis Forum is for the discussion of Slackware Linux.
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.
I have been reading a number of threads about changing kernels with Slack 12.1. When I first installed, I chose the huge-smp kernel because I suppose I misread the instructions and thought I needed that with a dual core processor. But, in the CHANGES_AND_HINTS it indicates that I should have used the generic-smp kernel.
The huge kernel has been working fine for me and I have the fglrx drivers installed. However, boot times are a little sluggish and overall speed while I am running the OS seems slightly less than I remember Slack being in the past. I was just curious to find out if I would get any noticable performance boost with the generic kernel. But, there are two caveats:
1. I want to continue to be able to boot the system as it is, and
2. I am using grub, not lilo.
Is it possible to be able to boot two kernels, choosing between them at boot?
Yes, you can have multiple kernels on a system and choose which to boot using GRUB.
GRUB should be controlled by /boot/grub/grub.conf or /boot/grub/menu.lst (I don't know which way Slack does it.) In it, there will be entries for each kernel, comprised of four lines...
title ...
root ...
kernel ...
initrd ...
Somewhere above those, there will be a "default=" line to tell the system which to boot if you don't make a choice.
The huge kernel has been working fine for me and I have the fglrx drivers installed. However, boot times are a little sluggish and overall speed while I am running the OS seems slightly less than I remember Slack being in the past. I was just curious to find out if I would get any noticable performance boost with the generic kernel.
You *may* notice a *slight* speed increase, but it won't be much, if anything. At least, that's my experience. Bootup time may decrease slightly since fewer modules are loaded, and RAM use *may* (but almost certainly won't) decrease since fewer modules are loaded, but I don't think you'll notice much of a difference in running speed. However, I would still recommend using the generic-smp kernel over the huge-smp kernel. I personally have two options -- I can either boot the generic-smp kernel (default) or the huge-smp kernel (I must manually select that at the LILO prompt). You can use the same setup for GRUB (though the syntax of the kernel stanza in menu.lst will be different than lilo.conf).
You must create an initrd (initial ramdisk) to use the generic kernel since the filesystems and some hard drive controllers are compiled as modules instead of built into the kernel. See /boot/README.initrd for more information. For a nice script that usually outputs the correct mkinitrd command to use (to generate the initrd), see here. The mkinitrd command will create a /boot/initrd.gz file and a /boot/initrd-tree directory. Then, add a stanza for your generic-smp kernel (while leaving your huge-smp kernel stanza alone to make sure you can still boot using that). My LILO kernel stanzas are shown below (Note: they WILL have to be adapted to menu.lst style. I'm not proficient with that so I won't try to create the correct syntax, since I may screw it up).
You should be able to copy your old kernel stanza and just change the location of the kernel to match the generic-smp one, and add the initrd part. A quick google search found this page. Although it's for Ubuntu, it has a menu.lst stanza that shows the syntax of adding an initrd. Note that by default Slackware's initrd will be located at /boot/initrd.gz, as shown in my LILO stanzas. Beyond that, you should probably just copy your existing stanza to the letter.
I know how to put the correct entries in Grub, but I was not sure how to set up two different kernels because, as I understand it, Slackware uses a symlink from vmlinuz to the huge-smp kernel, so I guess my question is more about the system configuration files and whether I could point grub directly to the kernel I wanted to boot without dealing with the system configuration files (knowing that I need an initrd with the generic kernel, which I have already made.). So, my question is, if I alter Grub (which is not a Slackware file, but Slack boots from it) to look like something like this:
There is a system map and system config file for each kernel. The ATI drivers are installed on the currently running huge kernel, but since I have never tried the generic kernel, I am assuming I would have to download a new driver file for that kernel as well. My desire is NOT to mess up what I already have because it is working nicely.
Bob.
I am doing exactly what you want. I have installed the huge-smp & generic-smp kernels. My /boot/grub/menu.lst file:
Thank, TSquaredF. That is exactly what I wanted to know. Since there is a system map and config file, I guess I just need to point grub to the correct kernel, but I am still wondering about the ATI drivers, will need to install a new one for the generic kernel>
Thanks. The whole point was to decrease boot time and boot performance, but if I am going to little or none of either, I am not going to mess with the system and risk it. Slack is the best performing distro I have now, and if can't improve on that I might as well just leave it alone.
Thank, TSquaredF. That is exactly what I wanted to know. Since there is a system map and config file, I guess I just need to point grub to the correct kernel, but I am still wondering about the ATI drivers, will need to install a new one for the generic kernel>
Bob
I don't worry about linking config or System.map. I make two links, "huge" & "generic" to the appropriate kernel. I'm using copies of the same kernels in my laptop, desktop & server machines. I have the same partition layout on the laptop & the desktop, so use the same menu.lst for both of them. Keep it all in a seperate boot partition & backups are almost automatic. I built the ATI driver for my laptop with scripts from SBo under the huge kernel & it works with the generic kernel as well.
Regards,
Bill
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.