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.
# Since upstream apparently can't be bothered, let's fix using ext* filesystems
# created with what are now the default options:
zcat $CWD/7fd5feff97c4b1f446f8fcf6d37aca0c64e7c763.patch.gz | patch -p1 --verbose || exit 1
I use for 2 years the slackbuild grub-2.06-x86_64-4 with:
--enable-libzfs=no \
--enable-efiemu=no \
--enable-grub-themes=no \
--enable-grub-emu-pci=no \
(don't judge me i'm a caveman )
grub-2.06-x86_64-4.txz 5,2 Mo
now with grub-2.06-x86_64-5 with:
--enable-libzfs=no \
--enable-efiemu=no \
--enable-grub-themes=no \
--enable-grub-emu-pci=no \
grub-2.06-x86_64-5.txz 12,2 Mo
No problem here with your config (only ~4k)
Code:
$ ls -l /tmp/grub-2.06-x86_64-*
-rw-r--r-- 1 root root 10206068 Aug 13 13:42 /tmp/grub-2.06-x86_64-4.txz (without the patch, more or less the same size on cumulative: https://slackware.uk/cumulative/slackware64-current/slackware64/a/grub-2.06-x86_64-4.txz)
-rw-r--r-- 1 root root 10202388 Aug 13 13:37 /tmp/grub-2.06-x86_64-5.txz (with the patch)
If another OS wants to see versioned initrd, you can still use a single /boot/initrd.gz for multiple kernels, if you add versioned symlinks to it.
And who/what will make your initrd and these symlinks? You by hand or a script will do the job on fly?
I believe that the fundamental question is the one put by ZhaoLin1457 in this thread: will be there a single package for kernel and its modules which execute on its install/doinst.sh a script customizable by user?
The root feature which gives to user the freedom to customize as he like is this snippet on that package install/doinst.sh
Code:
if [ -x boot/setup-kernel ]; then
/bin/chroot . /bin/sh -c "/boot/setup-kernel @@KERNEL_VERSION@@"
fi
I believe that does not matters if is better a mega-initrd (even with versioned symlinks) or the ones with versioned names like everybody else uses, or that you prefer to write by hand a /boot/grub/grub.cfg or not, as long this feature exists.
Heck, the Slackware even does not need to ship that /boot/setup-kernel script, as long that that 3 lines snippet exists on the install/doinst.sh from that package which ship both the kernel and its modules.
BUT, if this feature exists, the Slackers can choose from a fully manual configuration of initrd and GRUB2 up to a fully automatic configuration of them. As the Slackers themselves like.
Last edited by LuckyCyborg; 08-13-2023 at 09:51 AM.
What I am about to request is dumb and extremely low priority but why the hell not? Are we going to get some kind of awesome branding / image used when GRUB2 is official? You know like what Debian does - Or any other distro....
So, officially, the tools and such will only support one kernel? I thought suggested practice for Slackware was to always have two: one working, one backup.
So, officially, the tools and such will only support one kernel? I thought suggested practice for Slackware was to always have two: one working, one backup.
I for one, I believe that the best backup kernel is the working one.
BUT, there is still no way to do "upgradepkg /path/to/kernel-*.t?z" and the $(uname -r) kernel still to survive on reboot.
The guys and ladies who upgraded to 5.15.118 on a -stable release of Slackware, all of them using AMD graphics probably will agree with me.
Last edited by LuckyCyborg; 08-13-2023 at 10:01 AM.
What I am about to request is dumb and extremely low priority but why the hell not? Are we going to get some kind of awesome branding / image used when GRUB2 is official? You know like what Debian does - Or any other distro....
I don’t remember we do things like any other distro
AFAIK, Pat always provides most of the time, untouched pkg from source. I don’t see any reason for that to change
What I am about to request is dumb and extremely low priority but why the hell not? Are we going to get some kind of awesome branding / image used when GRUB2 is official? You know like what Debian does - Or any other distro....
Well, I can tell you that the GRUB2 has support for this kind of graphics, and on the Internet you can find plenty of tutorials for this.
You can start by looking in /etc/default/grub and the GRUB2 man pages.
So, officially, the tools and such will only support one kernel? I thought suggested practice for Slackware was to always have two: one working, one backup.
installpkg and removepkg support multiple kernels. A single initrd.gz can support multiple kernel versions. Remember to blacklist kernel for slackpkg.
I don’t remember we do things like any other distro
AFAIK, Pat always provides most of the time, untouched pkg from source. I don’t see any reason for that to change
breeze-grub may be a good start ��
Except if you use the menu in LILO you get a Slackware brand image...
installpkg and removepkg support multiple kernels. A single initrd.gz can support multiple kernel versions. Remember to blacklist kernel for slackpkg.
When the users are forced to download manually the kernel packages and to install manually the kernel packages, the fact that "a single initrd.gz can support multiple kernel versions" becomes rather a matter of Slacker's taste.
I do not see how a mega-initrd will be interesting even on the case when the user do this manually installation of the kernel packages.
Even when it's used an "untouchable" /boot/grub/grub.cfg , the user can just make symlinks to /boot/initrd-latest.gz and /boot/initrd-previous.gz while making initrds with versioned names. Manually.
Last edited by LuckyCyborg; 08-13-2023 at 11:33 AM.
We're talking Slackware, though. The average Slackware user is used to doing at least some things manually. Those who want to live on the edge can still use slackpkg, et al to handle their kernel. Those who wish to automate more can do that, too.
It's like the argument my partner and I have about automation, scripting, etc. I don't trust scripts because I don't trust that the script will get it right. He doesn't trust doing things manually, because he doesn't trust that he'll get it right. (It's a mixed marriage. I like Slackware. he likes Alma/Windows. )
Yes. There are two orthogonal problems and their solutions.
Use grub instead of (e)lilo as a boot loader.
Automatically install a new kernel, modules, and initrd, possibly leaving working versions of $(uname -r) as a backup.
I think Patrick is now solving problem number one. Of course, it would be nice to also solve problem number two, but it could have been solved a long time ago, or it can be solved in the far future. It's not directly connected to lilo/grub choice.
Last edited by Petri Kaukasoina; 08-13-2023 at 11:51 AM.
Yes, you are right. For the stock mkinitrd the -F parameter is mandatory.
Seems like ZhaoLin1457 still uses (just like me) a /sbin/mkinitrd to which have applied long time ago this patch bellow (made by me) for Slackware 15.0:
Code:
--- mkinitrd.orig 2022-01-26 22:33:29.000000000 +0200
+++ mkinitrd 2023-08-13 19:38:19.084631792 +0300
@@ -85,10 +85,6 @@
root filesystem is available. Other binaries may be added to the
initrd, and the script is easy to modify. Be creative. :-)
- -F Use the contents of /etc/mkinitrd.conf (optional)
- If this is used in conjunction with any other options passed
- on the command line, the command-line options will override
- the config file options. See mkinitrd.conf(5) for details.
-c Clear the existing initrd tree first
-f Filesystem to use for root partition (must be used with -r)
--help Display this message
@@ -342,17 +338,10 @@
fi
fi # default no-option actions
-# Parse for the use config file option first or else the other command
-# line options can not override /etc/mkinitrd.conf.
-for opt in "$@"; do
- if [ "$opt" = "-F" ]; then
- if [ -e /etc/mkinitrd.conf ]; then
- . /etc/mkinitrd.conf || badconf_file
- else
- badconf_file
- fi
- fi
-done
+# Include the configuration file.
+if [ -e /etc/mkinitrd.conf ]; then
+ . /etc/mkinitrd.conf || badconf_file
+fi
# Parse options:
while [ ! -z "$1" ]; do
My rationale for this patch is that a program (or script) should use in a mandatory way its configuration file, not in an optionally way how does the stock /sbin/mkinitrd . Yeah, probably the patch can be improved.
And yes, I played a bit with this script in the past, and me and ZhaoLin1457 shared along our experiences regarding the scripting of the boot(loader) setup.
Last edited by LuckyCyborg; 08-13-2023 at 11:55 AM.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.