LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 01-03-2018, 10:49 AM   #31
Darth Vader
Senior Member
 
Registered: May 2008
Location: Romania
Distribution: DARKSTAR Linux 2008.1
Posts: 2,727

Rep: Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247

Yep, that works, BUT only from a proper booted installation. Either way, mkinitrd will be confused about the root device.
 
Old 01-03-2018, 10:50 AM   #32
jkh2cpu
Member
 
Registered: Feb 2014
Location: Michigan, USA
Distribution: slackware
Posts: 281

Original Poster
Rep: Reputation: 60
Are you trying this with the latest offerings from slackware64-current?

And yes, my mkinitrd is about the same as yours, without the stuff after -m ext4.

John.
 
Old 01-03-2018, 10:52 AM   #33
Darth Vader
Senior Member
 
Registered: May 2008
Location: Romania
Distribution: DARKSTAR Linux 2008.1
Posts: 2,727

Rep: Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247
More precisely, what command you use?
 
Old 01-03-2018, 10:52 AM   #34
sombragris
Member
 
Registered: Jul 2004
Location: Asuncion, Paraguay, South America
Distribution: Slackware
Posts: 855

Rep: Reputation: 383Reputation: 383Reputation: 383Reputation: 383
Situation seemingly back to normal here. This thread has been priceless.

Thanks for the info. This answer by Darth Vader was especially useful.

However, a caveat: mkinitrd_command_generator may not be generally useful. Be careful.

I booted using an old kernel 3.8x bootable media I had around, followed the steps, and everytyhing went alright save for the mkinitrd_command_generator part. Somehow it prepares its modules taking into account the boot media. So when I applied the command generator, all I got was "No modules for kernel 3.8.x". Not useful.

I would suggest reading README.initrd in your root directory. In my case, while chrooting, I just typed:

Code:
  mkinitrd -c -k 4.14.11 -m ext4 -f ext4 -r /dev/sda2
and that simple command line generated a working initrd. After that I was able to boot.

Hope everyone could recover from this snafu without much sweat.

Last edited by sombragris; 01-03-2018 at 10:59 AM.
 
Old 01-03-2018, 10:56 AM   #35
sombragris
Member
 
Registered: Jul 2004
Location: Asuncion, Paraguay, South America
Distribution: Slackware
Posts: 855

Rep: Reputation: 383Reputation: 383Reputation: 383Reputation: 383
Quote:
Originally Posted by Darth Vader View Post
You are only a victim of your own laziness.

You are supposed to switch to the generic kernel and initrd after the first boot of your operating system. The huge one is/was only a workaround for the first boot, nothing more.
I resent being called lazy. That was completely uncalled for and totally inappropriate.

I do switch to a generic kernel!

After a kernel upgrade I boot once into the upgraded huge kernel, generate my initrd, and then reboot into the generic kernel.

However, this particular problem presented itself when I was supposed to boot that single time from the huge kernel.

Last edited by sombragris; 01-03-2018 at 10:58 AM.
 
Old 01-03-2018, 10:56 AM   #36
Darth Vader
Senior Member
 
Registered: May 2008
Location: Romania
Distribution: DARKSTAR Linux 2008.1
Posts: 2,727

Rep: Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247
You can specify to mkinitrd_command_generator.sh which kernel you want to target, using something like.
Code:
/usr/share/mkinitrd/mkinitrd_command_generator.sh -k 4.14.11
 
Old 01-03-2018, 10:59 AM   #37
Darth Vader
Senior Member
 
Registered: May 2008
Location: Romania
Distribution: DARKSTAR Linux 2008.1
Posts: 2,727

Rep: Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247
Quote:
Originally Posted by sombragris View Post
I resent being called lazy. That was completely uncalled for and totally inappropriate.

I do switch to a generic kernel

After a kernel upgrade I boot once into the upgraded huge kernel, generate my initrd, and then reboot into the generic kernel.

However, this particular problem presented itself when I was supposed to boot that single time from the huge kernel.
Fair enough! I apologize!

And yes, I agree that the latest kernel updates contained an unexpected surprise.
 
1 members found this post helpful.
Old 01-03-2018, 11:04 AM   #38
Darth Vader
Senior Member
 
Registered: May 2008
Location: Romania
Distribution: DARKSTAR Linux 2008.1
Posts: 2,727

Rep: Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247
For the record, there is how I do myself:

I have a file called "/boot/mkinitrd.sh" with the following content
Code:
#!/bin/sh

KVERSION=4.14.11

KMODULES="xhci-pci:ohci-pci:ehci-pci:xhci-hcd:uhci-hcd:ehci-hcd:hid:usbhid:i2c-hid:hid_generic:hid-cherry:hid-logitech:hid-logitech-dj:hid-logitech-hidpp:hid-lenovo:hid-microsoft:hid_multitouch:jbd2:mbcache:ext4"

ROOTDEV="UUID=35689c2a-bb39-4444-90f1-1cdec17f85e4"
ROOTFS="ext4"

SWAPDEV="UUID=21e3d368-6558-4b12-b1ff-9b3da262f340"


mkinitrd -c -k "$KVERSION" -r "$ROOTDEV" -f "$ROOTFS" -m "$KMODULES" -h "$SWAPDEV" -u -M -w 5 -o /boot/initrd-${KVERSION}.gz

#
ln -sf initrd-${KVERSION}.gz initrd.gz

lilo
Then, I always INSTALL manually, BUT I do NOT UPGRADE the kernels, then I update KVERSION and execute the script.

After a successful reboot, eventually I remove the old kernels. Manually, too.

To note that I modify the /etc/lilo.conf accordingly and I have always the ability to boot the previous kernel, via another LILO entry.

Last edited by Darth Vader; 01-03-2018 at 11:12 AM.
 
1 members found this post helpful.
Old 01-03-2018, 11:08 AM   #39
Petri Kaukasoina
Senior Member
 
Registered: Mar 2007
Posts: 1,781

Rep: Reputation: 1459Reputation: 1459Reputation: 1459Reputation: 1459Reputation: 1459Reputation: 1459Reputation: 1459Reputation: 1459Reputation: 1459Reputation: 1459
It's also possible to add parameters to /etc/mkinitrd.conf. See /etc/mkinitrd.conf.sample and 'man mkinitrd.conf'.
 
1 members found this post helpful.
Old 01-03-2018, 11:12 AM   #40
mralk3
Slackware Contributor
 
Registered: May 2015
Distribution: Slackware
Posts: 1,900

Rep: Reputation: 1050Reputation: 1050Reputation: 1050Reputation: 1050Reputation: 1050Reputation: 1050Reputation: 1050Reputation: 1050
Quote:
Originally Posted by Petri Kaukasoina View Post
It's also possible to add parameters to /etc/mkinitrd.conf. See /etc/mkinitrd.conf.sample and 'man mkinitrd.conf'.
Beat me too it! Also:
https://docs.slackware.com/slackbook:booting#mkinitrd
 
Old 01-03-2018, 11:14 AM   #41
Darth Vader
Senior Member
 
Registered: May 2008
Location: Romania
Distribution: DARKSTAR Linux 2008.1
Posts: 2,727

Rep: Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247
You guys are both right, but I have my personal taste on treating this business, as everyone.

And I consider the boot a very serious business, which I prefer to handle step-by-step with my own hands.
 
Old 01-03-2018, 11:18 AM   #42
jkh2cpu
Member
 
Registered: Feb 2014
Location: Michigan, USA
Distribution: slackware
Posts: 281

Original Poster
Rep: Reputation: 60
OK, fixed.

I needed to add mount -o bind /usr /mnt/usr for mkinitrd to run to completion.

Darth, you make it sound much harder than it actually is.

That machine boots.

Thanks for the help, guys.

John.
 
Old 01-03-2018, 11:26 AM   #43
Darth Vader
Senior Member
 
Registered: May 2008
Location: Romania
Distribution: DARKSTAR Linux 2008.1
Posts: 2,727

Rep: Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247Reputation: 1247
Quote:
Originally Posted by jkh2cpu View Post
OK, fixed.

I needed to add mount -o bind /usr /mnt/usr for mkinitrd to run to completion.

Darth, you make it sound much harder than it actually is.

That machine boots.

Thanks for the help, guys.

John.
Yeah, man! You are right! I need to throw my crystal ball, it not seen your custom /usr mount point. Sorry!

BUT, so far so good for you. Maybe you are kind to mark this thread as solved?

Psst. Marking some guys responses as useful, may make them a bit happy, too...
 
Old 01-03-2018, 11:39 AM   #44
sombragris
Member
 
Registered: Jul 2004
Location: Asuncion, Paraguay, South America
Distribution: Slackware
Posts: 855

Rep: Reputation: 383Reputation: 383Reputation: 383Reputation: 383
I would expect a new -current update with a fixed huge kernel before marking this as solved. The issue persists and many folks are going to be bitten by this "surprise" (as Darth Vader said and which describes the situation very well).

Last edited by sombragris; 01-03-2018 at 11:48 AM.
 
Old 01-03-2018, 11:52 AM   #45
sombragris
Member
 
Registered: Jul 2004
Location: Asuncion, Paraguay, South America
Distribution: Slackware
Posts: 855

Rep: Reputation: 383Reputation: 383Reputation: 383Reputation: 383
Well, one thing is clear. A situation like this in other distros would have us reinstalling at the very least. Thankfully in Slackware we have a robust architecture, tools that work, and fellow users which are patient and willing to guide others to a solution. I am really grateful for Slackware.
 
1 members found this post helpful.
  


Reply



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
[SOLVED] slackpkg upgrade-all is not working in slackware64-current foobarz Slackware 1 08-13-2012 01:55 PM
[SOLVED] Can't get slackpkg to upgrade to slackware64 NightSky Slackware - Installation 4 06-09-2010 04:38 PM
Slackware64 -current (20-04-2010) problem with slackpkg mlpa Slackware 5 04-22-2010 01:55 AM
[SOLVED] slackpkg insists on NOT upgrading me to slackware64-current. What am I missing? GrapefruiTgirl Slackware 5 03-04-2010 01:01 PM
Slackware64-Current / slackpkg slackass Slackware 31 06-06-2009 10:51 PM

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

All times are GMT -5. The time now is 01:11 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