LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   Handling NVMe devices in Slackware : Call for testing. (https://www.linuxquestions.org/questions/slackware-14/handling-nvme-devices-in-slackware-call-for-testing-4175597516/)

AlleyTrotter 03-07-2017 08:45 AM

Quote:

Originally Posted by laprjns (Post 5679975)
Changing the label(-L) is not doing what you think it is. efibootmgr, Booth Boot0004 and Boot005 have the same label, Salix, with one pointing to a boot loader for Slint and the other to Salix. So the real problem is when eliloconfig creates the Slackware directory on the ESP (EFI/Slackware) and copies the kernel, initrd and bootloader to it. If there is already a Slackware directory on the ESP, then it will be overwritten, but I do believe the installer warns about this.

Yes you are correct the installer does warn, However in my case on the first attempt I ignored the warning and allowed the Slackware entry to be over written it did not create a second Slackware entry but completely hosed the Slackware UEFI entry which could no longer boot. I was only able to recover by using the boot manager to use an entry on a second drive.
I hope that more clearly explains my issue and my solution. It is a simple change I used for successful testing as requested.

[EDIT]
I admit I am not the best splainer in the hood,
and I don't want to cause anyone unnecessary woe.
I am sure when I pressed F11 to bring up my boot manager screen
There was only one 'Slackware' and it would not boot
[/EDIT]
[EDIT] Last edit I promise. Just to satisfy my own curiosity I erased the nvme board and restarted from scratch. Booted with the 'fakeInstaller' iso and installed slackware64-14.2 from a HD partition. I could not install lilo (that is a lilo problem). Made a boot stick which works. The patched eliloconfig worked flawlessly. It erased the current Slackware UEFI entry and added a new Slackware UEFI entry which works.
As far as my system is concerned Didier's patches are ready for prime time.[/EDIT]
John

becken 04-05-2017 05:08 AM

Hi Didier,

I had the pleasure to try your patches today on a 5th gen ThinkPad X1 Carbon.

First, I installed Slackware 14.2 using the stock usbboot.img, wondering why
it suggested not to install LILO and then never offered to install ELILO. Then
I found this thead, booted using your ISO, ran configure which now mounted
the EFI System Partition and installed ELILO onto it.

Like John, I managed to forget patching eliloconfig, so there was a third
round through configure to have the boot entry installed in the firmware.

Quote:

Originally Posted by Didier Spaier (Post 5655362)
  • Is your swap partition (if any) on NVMe recognized by the installer?
  • Is your Linux partition on NVMe recognized by the installer?
  • Is elilo properly installed in the ESP on the NVMe?
  • Is the elilo boot entry successfully written in the firmware's boot menu?

Both swap and Linux partitions were recognized on NVMe even with stock image.
ELILO seemed to be properly installed with your image even with missing patch.
ELILO boot entry was only written to firmeware after applying eliloconfig.diff

Cheers!

Stmpjmpr 05-07-2017 04:54 AM

Hi Didier,

Maybe a bit of a late reply, and maybe not of much use (anymore), but I tested your eliloconfig.diff successfully on my new Thinkpak T470p. Lilo installs on the ESP and a boot entry is added to the firmware.

Unfortunately, I did not get to test the swap partition and Linux partition detection: Hardware support issues, unrelated to this topic, made me decide to (temporarily) switch to Arch Linux.

cheers!

Didier Spaier 05-07-2017 05:17 AM

Hi Stmlpjmpr and welcome to this forum.

Thanks for your reply, still helpful as a confirmation even with the patches now applied in Slackware-current, thanks Pat.

This leads me to mark this thread as [SOLVED].

Maybe you could tell us a little more about your hardware support issues, so that we can check that they be addressed at least in next Slackware release.

Stmpjmpr 05-07-2017 06:35 AM

Hi Didier,

Glad I could help.

Off topic:
My hardware problem: The SW 4.4 kernel somehow was unable to detect my ethernet adapter (Intel i219-V) properly. This surprised me, as this device is in use for a while now. lspci did output something, but I remember it was very brief.

I tried several kernels, also non-Slackware such as systemrescuecd. With the latest systemrescuecd (5.0.0, date 2017-04-23, kernel 4.9.24) it worked, as well as with Arch kernel 4.10.13-1. lspci Was more verbose here. In contrast, an old systemrescuecd I had made earlier in January 2017 was unable to properly detect and load the e1000e-driver.

For now, I use Arch for a while to more easily familiarise with the hardware. In case I happen to find out more, I'll get back to you.

cheers!

Freaksta 05-09-2017 11:21 AM

I ended up just moving my /dev/sda1 'boot' partition (EFI/ESP) to my NVME and rewrote my EFI boot loader entry via 'efibootmgr' ... I found this process to be easier given my configuration, but I wholly support your work here and I'd like to say thank you for tackling this project, and I'm very excited for this to be patched into -current and eventually Stable.

For any interested, moving your EFI partition from one drive to another is very easy.

Code:

dd if=/dev/sda1 of=/dev/nvme0n1p1
edit your fstab for your /boot/efi entry to point to your nvme (nvme0n1p1 in my case) ... I literally just changed the line from
Code:

/dev/sda1 to /dev/nvme0n1p1
and left the rest.
Replace your EFI boot entry with 'efibootmgr' .. I used
Code:

efibootmgr -c -d /dev/nvme0n1 -p 1 -L Slackware -l \\EFI\\Slackware\\elilo.efi
I removed my old EFI boot entry via
Code:

efibootmgr -B -b 0000
where '0000' is the value of your entry ID (0000,0001, or 0002, etc)

and that's it. I can now completely wipe/remove my /dev/sda SSD and just use my NVME

AlleyTrotter 05-09-2017 02:52 PM

What about your elilo.conf file. I believe you must also edit your default boot in that file?
John

Freaksta 05-09-2017 03:07 PM

Quote:

Originally Posted by AlleyTrotter (Post 5708320)
What about your elilo.conf file. I believe you must also edit your default boot in that file?
John

At least in my case, I've always kept my initrd.gz file in /boot/efi/EFI/Slackware/initrd.gz, instead of just /boot. For elilo.conf, I use
Code:

initrd=initrd.gz
since they're both in the same directory (/boot/efi/EFI/Slackware/ initrd.gz and elilo.conf) and I needed to make zero modifications.

Cheers!

Didier Spaier 05-09-2017 03:26 PM

I will add that elilo can only "see" files in the same EFI system partition (ESP) as the EFI image. This is why eliloconfig copies the kernel and case occurring the initrd from /boot to the ESP instead of just linking to them in the config file. The same limitation applies to elilo.conf.

Instead GRUB can have its files in different partitions, at the expense of an increased complexity as that needs modules to handle all file systems used to store the files, while elilo can only handle a FAT filesystem.

AlleyTrotter 05-09-2017 03:33 PM

I use elilo.conf to support multiple kernels and multiple root=/dev. That's why I assumed you would need to edit.
ie bzImage-4.11.0 and bzImage-4.4.14 or bzImage-4.9.6 etc.
This is my current elilo.conf on my NVME device (I use multiple bootable devices)
Code:

chooser=simple
delay=50
timeout=1
#
image=bzImage-4.11.0
        label=4110
        read-only
        append="root=/dev/nvme0n1p2 vga=normal ro"
#
image=bzImage-4.10.15
        label=last
        read-only
        append="root=/dev/nvme0n1p2 vga=normal ro"
#
image=bzImage-4.4.14
        label=SDA
        read-only
        append="root=/dev/sda2 vga=normal ro"
#
image=vmlinuz-3.13.3-lfs-7.5
  label=lfs
  read-only
  append="root=/dev/sdb8 vga=normal ro"
#
# was image=bzImage-rescue
image=bzImage-4.6.3
  label=rescue
  read-only
  append="root=/dev/sdb2 vga=normal ro"
#
image=bzImage-4.4.14
  label=build
  read-only
  append="root=/dev/sdb4 vga=normal ro"
#

I guess I'm very old school
John

Freaksta 05-09-2017 04:31 PM

You're still correct. I do need to edit my elilo.conf, just not due to the fact that I'm moving it from /dev/sda1 to /dev/nvme0n1p1 ... I do however use the generic vmlinuz since I tend to stay on the supported kernel now that all my hardware is supported. So, I guess my need is a little less, but yes, you are right.

Also, I find compiling a new kernel in LUKS tends to break stuff, but I'm sure I'm doing something wrong. :-)

Quote:

Originally Posted by AlleyTrotter (Post 5708336)
I use elilo.conf to support multiple kernels and multiple root=/dev. That's why I assumed you would need to edit.
ie bzImage-4.11.0 and bzImage-4.4.14 or bzImage-4.9.6 etc.
This is my current elilo.conf on my NVME device (I use multiple bootable devices)
Code:

chooser=simple
delay=50
timeout=1
#
image=bzImage-4.11.0
        label=4110
        read-only
        append="root=/dev/nvme0n1p2 vga=normal ro"
#
image=bzImage-4.10.15
        label=last
        read-only
        append="root=/dev/nvme0n1p2 vga=normal ro"
#
image=bzImage-4.4.14
        label=SDA
        read-only
        append="root=/dev/sda2 vga=normal ro"
#
image=vmlinuz-3.13.3-lfs-7.5
  label=lfs
  read-only
  append="root=/dev/sdb8 vga=normal ro"
#
# was image=bzImage-rescue
image=bzImage-4.6.3
  label=rescue
  read-only
  append="root=/dev/sdb2 vga=normal ro"
#
image=bzImage-4.4.14
  label=build
  read-only
  append="root=/dev/sdb4 vga=normal ro"
#

I guess I'm very old school
John


MarcT 05-11-2017 06:35 PM

Thanks for your work on this. I've installed -current twice on the same nvme equipped machine recently. The first time around was a very manual process, but with your patches included in the latest -current it just worked.

It would be great to have the nvme-cli included as a package, and also in the installer initrd. I will ask in the "Requests for Current" thread.

sternone 07-15-2017 10:06 AM

Hello guys, thank you for your efforts, I got a P51 Lenovo with NVMe device, I'm going to try it on Monday, could the above fix my problem that the Ubuntu install works but the slackware isn't?

See this thread:

http://www.linuxquestions.org/questi...me-4175609849/

Cheers,

AlleyTrotter 07-15-2017 10:40 AM

I used Didier's boot cd and followed his instructions to install Slackware64-14.2. After a small hicup everything installed fine. I am now on Slackware64-14.2 with 12.2 huge kernel (self-compiled). All works fine since my install
John

sternone 07-15-2017 04:38 PM

Quote:

Originally Posted by AlleyTrotter (Post 5735234)
I used Didier's boot cd and followed his instructions to install Slackware64-14.2. After a small hicup everything installed fine. I am now on Slackware64-14.2 with 12.2 huge kernel (self-compiled). All works fine since my install
John

Thanks, fingers crossed...

IT would be easier to have a release date for the next slackware so it's just built in :-)


All times are GMT -5. The time now is 01:28 AM.