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.
So I'm aware this is a pretty popular topic so please don't bite too hard
I use Grub as my boot manager and as you can see below, there are two entries for Slackware:
Code:
menuentry "Slackware Linux (Slackware 13.37.0) (on /dev/sdc1)" {
insmod part_msdos
insmod ext2
set root='(hd2,msdos1)'
search --no-floppy --fs-uuid --set 949bee22-eca8-4a80-9975-2aa43ad851e9
linux /boot/vmlinuz-generic-2.6.37.6 root=/dev/sdc1
}
menuentry "Slackware Linux (Slackware 13.37.0) (on /dev/sdc1)" {
insmod part_msdos
insmod ext2
set root='(hd2,msdos1)'
search --no-floppy --fs-uuid --set 949bee22-eca8-4a80-9975-2aa43ad851e9
linux /boot/vmlinuz-huge-2.6.37.6 root=/dev/sdc1
}
I have no issues booting the huge kernel. However, I'd like to boot the generic kernel. I started searching online and came across some things I thought would take care of it. I then read the "README.initrd" file on the SlackDVD and thought it'd be a simple process. So I did the following...
From within "usr/share/mkinitrd" I ran "mkinitrd_command_generator.sh". The output is listed below:
But since the "huge" kernel works and that menu entry appears identical to the "generic" one, this shouldn't be an issue should it? I ran 'update-grub' afterwards to update the "grub.cfg" file. I'm using GRUB2 so it's full of that automated crap and doesn't like you to edit the "grub.cfg" file directly.
The huge kernel does not need an initrd, the generic one does.
By the way, why did you go out of your way to install grub2, when grub is on the install disc?
Got ya...
I've got grub2 on another hard drive that I've been using to boot whatever OS I need. I didn't install any bootloader for Slackware figuring I'd just use grub2 to boot it (since Slackware is on my third hard drive). However, I'm really sort of fed up with the fact grub2 wants you to run the "update-grub" script in order to generate the *.cfg file. I'm glad you told me that grub was on the install disk. I'm going to plan on either installing it or lilo later tonight in order to test out what you've said above. I know there's a file for custom entries on grub2 but then you just end up with whatever "update-grub" discovered plus what you've entered...what can I say, I don't like clutter
If you have grub2 on a different drive on the same machine, then you really don't need to install any bootloader.
What I do is to make a menu.lst file in /boot/grub with entries that are symlinks.
Then, when I update a kernel, I just update the symlinks myself and no update-grub is necessary to be able to boot.
You can even have an entry for vmlinuz-old and initrd-old.gz to be able to boot your previous kernel.
Here is what I use for my /boot/grub/menu.lst
Code:
title S64 3.0-git-latest
root (hd0,13)
kernel /boot/vmlinuz-git root=/dev/sda14 ro
title S64 3.0-git-previous
root (hd0,13)
kernel /boot/vmlinuz-git-old root=/dev/sda14 ro
title S64-huge latest
root (hd0,13)
kernel /boot/vmlinuz root=/dev/sda14 ro
Just make sure to add your initrd line to the generic entry
Understood, that way you don't need to update your menu.lst file, only the symlinks. I've tracked down why Grub2 won't detect the "initrd.gz" file. It wants it to be named something like "initrd.img" instead. I also realized I can turn off the "os_prober" feature of Grub2 so it'll stop telling me what my menu entries should be. That way, I can just maintain my own file, similar to what you've stated above. I'll wait to claim victory until I can give it a try later tonight...
Everything works! Thanks for your help...I ended up adding a "40_custom" file to Grub2 with the additional line "initrd /boot/initrd.gz" as you indicated above.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.