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.
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.
An even easier question with a longer answer, lol. And be warned, I've never actually tried this, and don't understand why you'd want to do this, but it should work.
First off, keep both source directory trees seperate
/usr/src/linux-2.4.18
/usr/src/linux-2.4.20
Go into each directory and compile each, and under each one, after compiling, copy arch/i386/boot/bzImage to /boot/vmlinuz-ide-2.4.18 and /boot/vmlinuz-ide.2.4.20 respectively. Don't forget to copy System.map and .config to /boot/ appropriately as well.
Finally, just edit /etc/lilo.conf to reflect each one, for example (and this is just the section of it that matters [and assuming your root partition is /dev/hda1]):
# Linux bootable partition config begins
image = /boot/vmlinuz-ide-2.4.18
root = /dev/hda1
label = LinuX_2_4_18
read-only # Non-UMSDOS filesystems should be mounted read-only for checking
image = /boot/vmlinuz
root = /dev/hda1
label = LinuX_2_4_20
read-only # Non-UMSDOS filesystems should be mounted read-only for checking
# Linux bootable partition config ends
Finally, just run lilo (maybe with the -v option to make sure it came out ok).
That should do it.
Good luck! (And I mean that, because this is theoretical based on helping teacup with his/her problem, as, like I said, I've never actually tried it myself.)
Heh... I had to fix the lawn mower and mow the lawn today.
OK. I made the changes to lilo using chroot and I got both kernels to display on the lilo boot menu. When I chose the new kernel (mykernel) I got a black screen with active hard drive lights. When I chose the old one (slack_old) it booted up just like it always did (no keyboard). I know that slack_old is my original working kernel because of the creation date. How would compiling a new kernel affect my old kernel's operational status? Grr...
So then, I tried recompiling the kernel again after changing some options and I get another blank screen. I have used shift + ? to check out every the information about every feature both times. I don't have a clue what I'm missing.
I deleted the older new kernel and replaced it with my original kernel.
At least I've learned about the chroot command now. Never used that before.
I'd recomend reinstalling /slackware/a/kernel-ide-2.4.20-(??).tgz (I forget the rest, but it's [supposed to be, even though it has minor differences] the same kernel as bare.i under kernels/ on the CD), slackware/k/kernel-source-2.4.20-(??).tgz (again, forgetting), /slackware/d/kernel-modules-2.4.20(??).tgz, and /slackware/d/kernel-headers-2.4.20(??).tgz to make sure everything's nice and clean, then recompiling, and see if you get the same problems. If you do, and it's not a big deal for the stuff you're trying to change, I wouldn't worry too much about it.
okay i am a newb.. and i read the first post on how to create a kernel for a newbie... and i got to this point
If you are using 8.1 or later, open /usr/src/linux/Makefile in a text editor, scroll to line 74 and
uncomment the the line #export INSTALL_PATH=/boot.
For 8.0 you must leave this line commented.
So...cd /usr/src/linux
pico Makefile
scroll to line 74 and
uncomment the the line #export INSTALL_PATH=/boot.
For 8.0 you must leave this line commented.
but i dont have a linux directory in my /usr/src... where is the Makefile?
but i dont have a linux directory in my /usr/src... where is the Makefile?
Do you have any directories in /usr/src at all? If not, or if you only have an RPM dirctory, then you'll need to install the kernel source first...
Download it HERE
Then cd to the directory you saved it in, and do installpkg kernel-source-2.4.20-noarch-5.tgz
Then you will have the directory and can edit the Makefile.
You may want to save your existing config (should be in /boot, and can be copied to /usr/src/linux before make menuconfig) so you can use it as a starting point for configuring your kernel if you are going to compile.
no i dont have a linux directory in my /usr/src.. i dont understand y i wouldnt have it.. i installed all the components i think from the slackware 9 cd... and everything went good... is there anything wrong with my linux if i dont have the linux directory? should it have come automatically when i installed slackware 9?
If you did the newbie install type (and I know for a fact the same holds true with the full install type, since it actually does NOT install everything) with Slack9, I don't think it installs the source by default for safety reasons. It's not that hard to do so right from the cd, however, rather than downloading....
Just throw the disc in AFTER you've booted (there's a lot more to it if you put it in before you boot ).
Then do this:
(this has to be done as root)
mkdir /cdrom
mount -vt iso9660 /dev/cdrom /cdrom
cd /cdrom/slackware/k
installpkg kernel-source-2.4.20-noarch-5.tgz
Doing so will create the directory you're looking for (/usr/src/linux [not to mention the kernel version-speficic one, /usr/src/linux-2.4.20]).
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.