LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   Boot Slackware on NVME SSD? (https://www.linuxquestions.org/questions/slackware-14/boot-slackware-on-nvme-ssd-4175586404/)

jkaidor 08-06-2016 12:03 AM

Boot Slackware on NVME SSD?
 
Hello,

I celebrated the release of 14.2 by building a new PC to run it. It's a mini-ITX board with a Xeon E3-1241, 32G of ECC RAM and a 512G Samsung 950PRO M2 SSD. This last is giving me heartburn.

The complete Slackware install happens, but then Lilo refuses to install itself. It complains that it can't handle the SSD device.

Somebody else asked similar:
https://www.linuxquestions.org/quest...ks-4175567831/

It looks like it ain't gonna work. Anybody know a workaround? Use
Slackware with a different bootloader? I downloaded the Lilo source and found the spot where it complains.... I suppose I could try adding that particular major # (259 ) to the "approved" list in geometry.c.

If all else fails, I could boot Slackware off a memory stick, and tell it to use the root directory on the fast SSD. Ick.

Thoughts? These NVME SSDs are only going to get more & more popular.
They're a bit pricy now, but they will come down... And they're over 3 times as fast as SATA SSDs.

- Jerryk

kjhambrick 08-06-2016 04:33 AM

jkaidor --

I agree about the NVMe devices -- they're already here !

I've got a pair of the 500GB Samsung 950 Pros in my Laptop as secondary drives where they work VERY well ( speed wise ).

As for booting Slackware from an NVMe ...

1. This guy:

https://rlaanemets.com/post/show/computer-upgrade

was able to boot an NVMe using syslinux installed in /boot/ on his 'old drive' ...

No direct help there but he does show how he used syslinux to 'auto-boot' Slackware installed in /root/ on the NVMe.

IOW, you should be able to boot into your new NVMe from a small USB Disk with syslinux to get things going.

2. And here's a question on the Arch Forum where booting directly via the EFI Shell is mentioned for a Non-Dual-Boot System:

https://bbs.archlinux.org/viewtopic.php?id=209653

Then, after you're up and running ...

3. This Stack Exchange post:

http://unix.stackexchange.com/questi...alling-debiavn

has a solution for Debian + grub-efi-amd64 and was adapted from this Debian Wiki Article ( #4 ) :

https://wiki.debian.org/InstallingDe...CIe_SSD/jessie

Maybe #1 or #2 will get you going where you could explore #3 and #4 ?

I am not sure what's contained in grub-efi-amd64.deb nor how entangled it may be with systemd but that is left as an 'exercise for the reader' :)

HTH, at least a little bit, I am still trying unlearn my old 1980 IBM-PC BIOS Habits and to wrap my old-fart brain-cells around all the new HW / SW tech :)

-- kjh

jkaidor 08-06-2016 10:27 AM

This worked:
https://rlaanemets.com/post/show/computer-upgrade
The syslinux instructions are near the bottom of the page.

After getting dumped into a root command line after setup...

I created a text file /boot/extlinux.conf:
-------- snip -----------
DEFAULT linux
SAY Now booting the kernel from SYSLINUX
LABEL linux
KERNEL vmlinuz
APPEND ro root=/dev/nvme0n1p1
-------- endsnip ------

And ran extlinux --install /boot

And then did a magic dd to get the generic syslinux code into the mbr:

cd /usr/share/syslinux
dd bs=440 conv=notrunc if=mbr.bin of=/dev/nvme0n1

...and then rebooted, and it Just Worked. Yay!

I still have a *lot* of work to do. I have been refining my server
for many years, and everything will need to be ported to this new machine.

Newer, higher tech makes this server simpler than the old one. I used to do all sorts of tricks with
multiple disks and partitions to make things faster. /home on a different device than /bin,/usr/bin etc. None of that is necessary with an SSD.
Just one big partition for everything. Except for a swap partition, which I am including out of an abundance of caution, although I do not
anticipate running out of physical RAM with 32G.

- Jerryk

slalik 08-06-2016 10:41 AM

I use 14.2 booted from NVMe disk, Samsung 950 in a Lenovo notebook and an Intel disk in a desktop computer (self-assembled).

I use UEFI and elilo. There is a minor problem with the installer that simply doesn't search for a EFI partition on an NVMe disk. I wrote how I worked around this problem here.

trxdraxon 08-07-2016 01:23 AM

Quote:

Originally Posted by jkaidor (Post 5586976)
This worked:
https://rlaanemets.com/post/show/computer-upgrade
The syslinux instructions are near the bottom of the page.

After getting dumped into a root command line after setup...

I created a text file /boot/syslinux.conf:
-------- snip -----------
DEFAULT linux
SAY Now booting the kernel from SYSLINUX
LABEL linux
KERNEL vmlinuz
APPEND ro root=/dev/nvme0n1p1
-------- endsnip ------

And ran extlinux --install /boot

And then did a magic dd to get the generic syslinux code into the mbr:

cd /usr/share/syslinux
dd bs=440 conv=notrunc if=mbr.bin of=/dev/nvme0n1

...and then rebooted, and it Just Worked. Yay!

I still have a *lot* of work to do. I have been refining my server
for many years, and everything will need to be ported to this new machine.

Newer, higher tech makes this server simpler than the old one. I used to do all sorts of tricks with
multiple disks and partitions to make things faster. /home on a different device than /bin,/usr/bin etc. None of that is necessary with an SSD.
Just one big partition for everything. Except for a swap partition, which I am including out of an abundance of caution, although I do not
anticipate running out of physical RAM with 32G.

- Jerryk


Thank you for this. I too just built myself a new machine with a NVME SSD and had the same issue and your post worked like a charm except that your syslinux.conf should be extlinux.conf. Just got Slackware installed and running updates and installing everything I need.

Wiser Slacker 08-07-2016 02:07 AM

i did my install by PXE boot from an raspberrry pi ... lol

have had no problems so far ...

jkaidor 08-07-2016 07:31 AM

Quote:

Originally Posted by trxdraxon (Post 5587262)
Thank you for this. I too just built myself a new machine with a NVME SSD and had the same issue and your post worked like a charm except that your syslinux.conf should be extlinux.conf.

*** Ooops. You're welcome. I just changed it to extlinux.conf.

- Jerry

kjhambrick 08-07-2016 08:56 AM

Thanks all !

When I received this new laptop, Sager had installed Win10 on one of the NVMe Cards -- it worked well and was Pretty-Dang-Quick.

I hit a wall trying to install to the other NVMe Card, chickened out and installed SlackWare64 Current on one of the Samsung 850 Pro SSDs instead and set up the pair of NVMe Disks as 'secondary'.

I now see three ways that I could have booted Slackware Current from an NVMe Card ( syslinux ala jkaidor or elilo ala slalik or PXE boot ala Wiser Slacker ).

Thanks again !

This Thread is a 'keeper'

-- kjh

kjhambrick 08-07-2016 09:47 AM

jkaidor --

If you consider your NVMe Install issue solved, it may help other users if you mark the Thread as SOLVED.

I usually start my LQ searches for fixes with 'Threads Marked SOLVED' and I'll bet that others do too.

Thanks !

-- kjh

jkaidor 08-07-2016 08:48 PM

Quote:

Originally Posted by kjhambrick (Post 5587380)
jkaidor --

If you consider your NVMe Install issue solved, it may help other users if you mark the Thread as SOLVED.

*** I have so marked it. - Jerry

Wiser Slacker 08-08-2016 09:40 PM

maybe it helps ...
 
Hi,

if you want to boot lilo to an nvme - where the other devices are changed, may be you put in some more sata drives - i did it this way:

My Problem had been that the device order did change when i put in another hd ...

1. i do install lilo into the mbr of that disk i want to boot from ...

2. give the boot statement by the line below to lilo.conf
boot = /dev/disk/by-id/ata-PLEXTOR_PX-G256M6e_Pxxxxxxxxx

3. than you should use the following statement to tell the kernel where the root disk is
Code:

  lilo.conf
  # Linux bootable partition on SSD2
  image = /boot/vmlinuz
    addappend = " root=PARTUUID=abcdefgh-02"    # here second partition
    label = Slack14
    read-only
  # Linux bootable partition SSD2 ends

blkid should give you the right "PARTUUID"

4. you should use the form of LABEL= or maybe /dev/disk/by-xxxxyyyyyzzzzz in fstab

5. tell the bios witch device you want to start from


now you are total free from any device order the bios tell to your booting os (here slackware ;) )
as i said before - the initial booting could be done by any device (maybe pxe as i do) witch is able to start the installer

all needed tools are already in the slackware installer

greetings
W.Slacker

bassmadrigal 08-09-2016 06:39 AM

Quote:

Originally Posted by Wiser Slacker (Post 5588233)
Code:

    addappend = " root=PARTUUID=abcdefgh-02"    # here second partition

Just so you know, you don't need to have it as an addappend. You can just use:

Code:

root = "PARTUUID=abcdefgh-02"
EDIT: Based on Wiser Slacker's post below, this may not be true for PARTUUID=, however, it will work if using UUID= or LABEL=.

Wiser Slacker 08-09-2016 09:51 AM

i have written:
Quote:

# root = "PARTUUID=abcdefgh-02" # Illegal 'root=' specification
into my lilo.conf - i think it didn't work - i have tried many combinations ...

to make it clear DON't use the
Quote:

root =
outside of the kernel line !!
the results are different !
and they may not do what you want or think off !!

bassmadrigal 08-09-2016 10:20 AM

Quote:

Originally Posted by Wiser Slacker (Post 5588455)
i have written:


into my lilo.conf - i think it didn't work - i have tried many combinations ...

Huh, maybe it doesn't support PARTUUID=. I do know it supports LABEL= and UUID= (I'm using the UUID variant on my lilo.conf), so I guess I wrongly assumed it would support PARTUUID=.

Wiser Slacker 08-09-2016 10:53 AM

i have had a look into kernelsource ...

/usr/src/linux/init/do_mounts.c

so with this option, i told here before, you don't need any initrd, the needed "device tree" was created by the kernel itself and LILO don't need to interpret any UUID's - the PARTUID is found by the kernel while booting and could be found in any disk partition table - ok. i just try "table msdos" yet ...

while lilo did write something like 0810 or 0820 into the kernels head before, for finding its partitions, it don't have to write these infos into the kernel now, but the kernel get its info from command line ....

and as i said - lilo seemed not to want your root option ... ok. you know ..

to keep it clear -
if you tell lilo-instaler to "interpret" what it should write into the boot loader it did that by following the /disk-by/ ... way and found the device ID - that could be wrong (after reboot) if you change any disks in your pc - so the kernel later can't find its root partition !

these are the most misinterpreted problems while booting any os's - the internet is full of those people who can't get its machines to boot ... mostly with windooofs


All times are GMT -5. The time now is 05:39 AM.