LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware > Slackware - Installation
User Name
Password
Slackware - Installation This forum is for the discussion of installation issues with Slackware.

Notices


Reply
  Search this Thread
Old 02-18-2021, 03:20 PM   #1
rogerxx
Member
 
Registered: Feb 2021
Location: Ohio
Distribution: Gentoo & Slackware
Posts: 42

Rep: Reputation: Disabled
"How to switch from Kernel Huge..." mkinitrd bugs


Slackware Documentation Project, "How to switch from Kernel Huge to Generic" seems to have bugs.

How to switch from Kernel Huge to Generic
https://docs.slackware.com/howtos:sl...ge_for_generic

I think I've nailed the problem down to "/usr/share/mkinitrd/mkinitrd_command_generator.sh -l \ /boot/vmlinuz-generic-4.4.172" (the lilo.conf generator), seems to be also re-running mkinitrd and re-editing what the previous mkinitrd_command_generator.sh incanatation wrote. This can be witnessed by the comment written by the lilo.conf generator, which omits many of the options utilized within my previously executed mkinitrd execution incanatation.

I have so far verified this, or worked around this problem, by re-running the mkinitrd_command_generator.sh incanatation. I have yet to perform multiple executions for verifying this bug, but am pretty sure with a fully booted mkinitrd after several hours, that this is the problem.

Not sure if this an upstream bug, where the "-l" switch is not suppose to overwite the mkinitrd tree/image, without the use of "-c" (clean mkinitrd tree) option.

Can I also suggest, a clean-up of this documentation, more clearly/consicely writing only the steps needed for a successful mkinitrd execution/install, and clearly separating some of the included hints/notes/explanations causing confusion? In other words, a lot of the explanations do not have enough uniform white space, for people to clearly see only the commands needed for successfully executing/acquiring mkinitrd images.

Last edited by rogerxx; 02-18-2021 at 03:30 PM.
 
Old 02-18-2021, 05:13 PM   #2
Alien Bob
Slackware Contributor
 
Registered: Sep 2005
Location: Eindhoven, The Netherlands
Distribution: Slackware
Posts: 8,559

Rep: Reputation: 8120Reputation: 8120Reputation: 8120Reputation: 8120Reputation: 8120Reputation: 8120Reputation: 8120Reputation: 8120Reputation: 8120Reputation: 8120Reputation: 8120
I am sorry to disappoint, but the "mkinitrd_command_generator.sh" script does not execute any "mkinird" command. The script will only show you what it thinks is a suitable "mkinitrd" command for your specific hardware configuration.
Perhaps you need to be more specific in your observations - for instance show us the commands you entered and the results they yielded.

As for "cleaning up" the documentation, I do not understand what you are referring to. YEs, this is a translation into English from another language and the author's grasp of English language is not the best, but it is understandable.
White space issues? How are you reading this article in the Wiki? Graphical browser or a text-based browser such as Lynx?
 
Old 02-18-2021, 08:16 PM   #3
rogerxx
Member
 
Registered: Feb 2021
Location: Ohio
Distribution: Gentoo & Slackware
Posts: 42

Original Poster
Rep: Reputation: Disabled
I already understand "mkinitrd_command_generator.sh" is a command line mkinitrd incanatation generator.
 
Old 02-19-2021, 10:25 PM   #4
rogerxx
Member
 
Registered: Feb 2021
Location: Ohio
Distribution: Gentoo & Slackware
Posts: 42

Original Poster
Rep: Reputation: Disabled
Here's my version of instructions, of course, using the previous cite's information.


For generating mkinitrd incanatations, use the interactive mkinitrd_command_generator.sh menus using "mkinitrd_command_generator.sh -i" option.
# /usr/share/mkinitrd/mkinitrd_command_generator.sh -i

Once a mkinitrd incanation is printed, copy and edit the incanatation as needed, then execute. For example:
# mkinitrd -c -k 4.4.240 -f ext4 -r /dev/sda2 -m jbd2:mbcache:ext4 -h /dev/sda1 -u -o /boot/initrd.gz

Check to ensure /boot/initrd.gz is updated, usually not needed.
# ls -al /boot/initrd.gz

If this is the first time using a newer kernel or have not already made an entry within lilo.conf with updated kernel version numbers, then execute the following. A new entry will be added to the bottom of /etc/lilo.conf. Edit the entry as needed.
# /usr/share/mkinitrd/mkinitrd_command_generator.sh -l /boot/vmlinuz-generic-4.4.240 >> /etc/lilo.conf

Edit /etc/lilo.conf as needed, then re-install/recycle writing lilo to MBR:
# lilo
 
Old 02-21-2021, 05:41 AM   #5
chrisretusn
Senior Member
 
Registered: Dec 2005
Location: Philippines
Distribution: Slackware64-current
Posts: 3,366

Rep: Reputation: 1832Reputation: 1832Reputation: 1832Reputation: 1832Reputation: 1832Reputation: 1832Reputation: 1832Reputation: 1832Reputation: 1832Reputation: 1832Reputation: 1832
Quote:
Originally Posted by rogerxx View Post
I think I've nailed the problem down to "/usr/share/mkinitrd/mkinitrd_command_generator.sh -l \ /boot/vmlinuz-generic-4.4.172" (the lilo.conf generator), seems to be also re-running mkinitrd and re-editing what the previous mkinitrd_command_generator.sh incanatation wrote. This can be witnessed by the comment written by the lilo.conf generator, which omits many of the options utilized within my previously executed mkinitrd execution incanatation.

I have so far verified this, or worked around this problem, by re-running the mkinitrd_command_generator.sh incanatation. I have yet to perform multiple executions for verifying this bug, but am pretty sure with a fully booted mkinitrd after several hours, that this is the problem.

Not sure if this an upstream bug, where the "-l" switch is not suppose to overwite the mkinitrd tree/image, without the use of "-c" (clean mkinitrd tree) option.

Can I also suggest, a clean-up of this documentation, more clearly/consicely writing only the steps needed for a successful mkinitrd execution/install, and clearly separating some of the included hints/notes/explanations causing confusion? In other words, a lot of the explanations do not have enough uniform white space, for people to clearly see only the commands needed for successfully executing/acquiring mkinitrd images.
I see no bugs in the how-to.

mkinitrd_command_generator.sh produces what it is supposed to
Code:
/usr/share/mkinitrd/mkinitrd_command_generator.sh
#
# mkinitrd_command_generator.sh revision 1.45
#
# This script will now make a recommendation about the command to use
# in case you require an initrd image to boot a kernel that does not
# have support for your storage or root filesystem built in
# (such as the Slackware 'generic' kernels').
# A suitable 'mkinitrd' command will be:

mkinitrd -c -k 4.4.240 -f ext4 -r /dev/sda1 -m jbd2:mbcache:ext4 -u -o /boot/initrd.gz
As does mkinitrd_command_generator.sh -l /boot/vmlinuz
Code:
/usr/share/mkinitrd/mkinitrd_command_generator.sh -l /boot/vmlinuz-generic
# Linux bootable partition config begins
# initrd created with 'mkinitrd -c -k 4.4.240 -f ext4 -r /dev/sda1 -m jbd2:mbcache:ext4 -u -o /boot/initrd.gz'
image = /boot/vmlinuz-generic-4.4.240
  initrd = /boot/initrd.gz
  root = /dev/sda1
  label = 4.4.240
  read-only
# Linux bootable partition config ends
Nothing is overwritten. What is shown here is the recommended command to usage for mkinitrd and a recommend /etc/lilo.conf entries based on the passed kernel.

Last edited by chrisretusn; 02-21-2021 at 05:47 AM. Reason: Changed to reflect kernel 4.4.240
 
Old 02-21-2021, 02:50 PM   #6
quickbreakfast
Member
 
Registered: Oct 2015
Location: northern territory
Distribution: slackware 15
Posts: 362

Rep: Reputation: Disabled
Quote:
Originally Posted by rogerxx View Post
Slackware Documentation Project, "How to switch from Kernel Huge to Generic" seems to have bugs.

How to switch from Kernel Huge to Generic
https://docs.slackware.com/howtos:sl...ge_for_generic
If the page your referring to had a bug, you would not be the only person who is having trouble changing to a generic kernel.

When first mentioned in your link the bit of code
Code:
 -l \ /boot/vmlinuz-generic-4.4.172"
isn't present.

Last edited by quickbreakfast; 02-21-2021 at 03:01 PM.
 
Old 02-21-2021, 08:53 PM   #7
chrisretusn
Senior Member
 
Registered: Dec 2005
Location: Philippines
Distribution: Slackware64-current
Posts: 3,366

Rep: Reputation: 1832Reputation: 1832Reputation: 1832Reputation: 1832Reputation: 1832Reputation: 1832Reputation: 1832Reputation: 1832Reputation: 1832Reputation: 1832Reputation: 1832
Quote:
Originally Posted by quickbreakfast View Post
If the page your referring to had a bug, you would not be the only person who is having trouble changing to a generic kernel.

When first mentioned in your link the bit of code
Code:
 -l \ /boot/vmlinuz-generic-4.4.172"
isn't present.
It is present on that page.
Code:
/usr/share/mkinitrd/mkinitrd_command_generator.sh -l \ /boot/vmlinuz-generic-4.4.172

image = /boot/vmlinuz-generic-4.4.172
  initrd = /boot/initrd.gz
  root = /dev/sda1
  label = 4.4.172
  read-only
# Linux bootable partition config ends
Perhaps you are referring to the missing '\' for @rogerxx's post.
Quote:
Originally Posted by rogerxx View Post
# /usr/share/mkinitrd/mkinitrd_command_generator.sh -l /boot/vmlinuz-generic-4.4.240 >> /etc/lilo.conf
The '\' is not needed.

Last edited by chrisretusn; 02-21-2021 at 08:55 PM.
 
Old 02-21-2021, 10:55 PM   #8
rogerxx
Member
 
Registered: Feb 2021
Location: Ohio
Distribution: Gentoo & Slackware
Posts: 42

Original Poster
Rep: Reputation: Disabled
Another possibility, lilo might not have been writing to MBR due to a lilo.conf error.

I could have been missing the failure due to lilo's tame error messages. Caught myself ignoring lilo's error messages the other night.

I think my instructions within Comment #4 are more simple and concise.
 
  


Reply


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
Huge kernel boots--Huge.SMP (and generic.smp) kernel will not MTCAT Linux - Newbie 4 02-03-2021 02:11 PM
LXer: The code's crashed again, but why? Tell us your war stories of bugs found – and bugs fixed LXer Syndicated Linux News 0 10-22-2018 03:21 PM
LXer: Languages don't breed bugs, PEOPLE breed bugs, say boffins LXer Syndicated Linux News 1 11-06-2014 12:56 PM
sudo mkinitrd -o /boot/initrd.img-2.6.32.9 2.6.32.9 sudo: mkinitrd: command not foun vishwas181 Linux - Newbie 1 02-27-2010 01:16 AM
slack 12, switch to generic kernel from huge kernel, using grub? jaguarrh Slackware 8 09-19-2007 06:29 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware > Slackware - Installation

All times are GMT -5. The time now is 07:43 AM.

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