LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
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 04-04-2020, 12:00 AM   #1
rudymartinx
LQ Newbie
 
Registered: Apr 2020
Location: Argentina
Distribution: Slackware!
Posts: 17

Rep: Reputation: Disabled
Finishing a slackware-current install on mmcblk device with UEFI


Hi all.

I have been using Slackware since many years (I think I used it first back in 1997), version 3, 7, 10, 11, 13 and now 14. What I love about it is they didn't changed the install procedure too much (iow: still console and still the same installer philosofy).- Over the years I followed the standard procedure (with a few modifications like not setting up a swap partition in favor of a swap file) and had no problems.

Today I have downloaded Alienbob current iso, dd it to a usb stick and I was able to install it on a cheap Chinese notebook (almost no brand name, can provide details of it if you need it), which only has UEFI boot and hard disk is /dev/mmcblk0

erased the partitions (it had Win10) and created the new ones: 100M for EFI and the rest for the Linux. then mkfs.vfat /dev/mmcblkp0p1

Installation went no problem with the sole exception of eliloconfig. During the setup process, when asked to install a boot menu entry, a line appears at the bottom saying "Could not prepare Boot variable: Success".

rebooted, then I was drop into EFI shell, which turns out is just a glorified modified MS-DOS shell. so I did

fs0:
cd EFI
cd Slackware

type elilo.conf


Quote:
chooser=simple
delay=1
timeout=1
#
image=vmlinuz
label=vmlinuz
initrd=initrd.gz
read-only
append="root=/dev/mmcblk0p2 vga=normal ro"
then I ran elilo.efi which boots linux

kernel loads then during the kernel boot it drop an error:

Quote:
mounting /dev/mmcblk0p2 on /mnt failed: no such File or directory
after that it says "No /sbin/init found on rootdev

I'm drop on a rescue shell but no /dev/mmcblk0 device is present. Tried to cheat using mknod but didn't work ( fdisk /dev/mmcblk0 it says cant open device) also tried modprobe mmc_core, no luck.

after reading a lot about UEFI installs and mmcblk, and since it is my first time dealing with a UEFI only computer, I decided to create a VMware with UEFI boot and did a normal install and everything was fine, and just to be sure it wasn't a setup problem.

can someone point me out what I am missing to make it boot completly ? *(I dont mind the EFI shell issue for now, unless I'm missing something important)

thanks in advance
 
Old 04-04-2020, 01:34 PM   #2
business_kid
LQ Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware, Slarm64 & Android
Posts: 17,418

Rep: Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590
First of all, we need more info on your box - as much as you have.

For UEFI on which I am no expert,I think you need 3 partitions, EFI, /boot, & /
Exactly what goes on them I don't know, but that's easily googled.
 
Old 04-04-2020, 01:53 PM   #3
colorpurple21859
LQ Veteran
 
Registered: Jan 2008
Location: florida panhandle
Distribution: Slackware Debian, Fedora, others
Posts: 7,809

Rep: Reputation: 1679Reputation: 1679Reputation: 1679Reputation: 1679Reputation: 1679Reputation: 1679Reputation: 1679Reputation: 1679Reputation: 1679Reputation: 1679Reputation: 1679
Quote:
For UEFI on which I am no expert,I think you need 3 partitions, EFI, /boot, & /
Two minimum, the efi partition for the efi bootloader and the / partition.

Maybe a driver for the mmcblk is missing from the kernel. an initrd may be needed.

Last edited by colorpurple21859; 04-04-2020 at 02:01 PM.
 
Old 04-04-2020, 02:34 PM   #4
business_kid
LQ Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware, Slarm64 & Android
Posts: 17,418

Rep: Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590
There is another feature. On boot, it's your bios talking to the sdcard reader. As soon as linux takes over, all sdcard drivers will all fall down, because they expect to be loaded after usb drivers, not before. So their code will be handing usb transactions to a usb driver which may not be loaded yet.
 
Old 04-04-2020, 04:15 PM   #5
rudymartinx
LQ Newbie
 
Registered: Apr 2020
Location: Argentina
Distribution: Slackware!
Posts: 17

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by colorpurple21859 View Post
Two minimum, the efi partition for the efi bootloader and the / partition.

Maybe a driver for the mmcblk is missing from the kernel. an initrd may be needed.
just built an initrd.gz on the virtual machine.

mkinitrd -m mmc_core

copied to a pen drive

then on the notebook, booted with the installer

mkdir linux
mount /deb/mmcblk0p2 /linux
mount /deb/mmcblk0p1 /linux/boot/efi
cd /linux/boot/efi/EFI/Slackware
mv initrd.gz initrd.gz.old
cp /pen/initrd.gz .

kernel boot says loading kernel modules from initrd.gz but error message stays the same

after that I repeated mkinitrd on the virtual machine, added -m mmc_core,mmc_block, same result but with the addition of keyboard freeze (or kernel hung)

about the computer, a kernel error says: hardware name Advantec CX23200W/Cherry Trail CR. Couldn't find on the net which kernel modules are really needed for this.

thanks again.
 
Old 04-05-2020, 03:45 AM   #6
business_kid
LQ Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware, Slarm64 & Android
Posts: 17,418

Rep: Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590
Frankly, I don't think you'll get away with grub or an initrd.

If you're want to give it what I think is your best shot, compile in your filesystem module, xhci_hcd and your sdcard reader module.I would dd that to the / (presuming it's mmcblk0p1 - EFI, & mmcblk0p2 - /) and hope the Bios gets you there. If the BIOS is uefi compliant, it has to get you past the partition table. mmcblk0p1 should be formatted FAT, incidentally.
 
Old 04-05-2020, 06:37 AM   #7
laprjns
Member
 
Registered: Oct 2005
Location: Connecticut USA
Distribution: SalixOS
Posts: 206

Rep: Reputation: 108Reputation: 108
From your opening post, you appear to have two problems. The first is an uefi booting problem with the menu entry that was created (or attempted to be created) during the Slackware install. Dropping into UEFI shell is normal behavior for the uefi firmware if it cannot find a valid menu entry to boot. Since you have a workaround using the UEFI shell for this I would ignore it for now since most likely it due to some quirk in the uefi firmware.

The second problem is that there is a mounting issue with the slackware root file system during booting of the installed Slackware. For some reason its being mounted on /mnt instead of /.
Code:
mounting /dev/mmcblk0p2 on /mnt failed: no such File or directory
I'm not sure why this is happening, but I suggest your try chrooting into your Slackware install on /dev/mmcblk0p2 and rerun eliloconfig.

Once you get a working slackware install then you can resolve the uefi menu problem.
 
Old 04-05-2020, 09:30 PM   #8
rudymartinx
LQ Newbie
 
Registered: Apr 2020
Location: Argentina
Distribution: Slackware!
Posts: 17

Original Poster
Rep: Reputation: Disabled
solved the task but not the problem.

Quote:
Originally Posted by business_kid View Post
Frankly, I don't think you'll get away with grub or an initrd.

If you're want to give it what I think is your best shot, compile in your filesystem module, xhci_hcd and your sdcard reader module.I would dd that to the / (presuming it's mmcblk0p1 - EFI, & mmcblk0p2 - /) and hope the Bios gets you there. If the BIOS is uefi compliant, it has to get you past the partition table. mmcblk0p1 should be formatted FAT, incidentally.
ty for your replies. It doesn't have bios emulation, just UEFI. I did read the posts you made before but since I have little info of this particular hardware it was hard for me to search on google for the propper modules. I was considering compiling a kernel (I have done it in the past but I'm not a fan of it because if you need to move the disk to another computer it may not boot) but without knowing which options I should enable, I realized I was going to get into a lot of trials until I get it to work. Also I did formated mmcblk0p1 as vfat.

My last try was to create a initrd using the modules loaded from the installer kernel, but it also failed.

I think I'm missing some more important and I guess I will have to read kernel docs.

Quote:
Originally Posted by laprjns View Post
From your opening post, you appear to have two problems. The first is an uefi booting problem with the menu entry that was created (or attempted to be created) during the Slackware install. Dropping into UEFI shell is normal behavior for the uefi firmware if it cannot find a valid menu entry to boot. Since you have a workaround using the UEFI shell for this I would ignore it for now since most likely it due to some quirk in the uefi firmware.

The second problem is that there is a mounting issue with the slackware root file system during booting of the installed Slackware. For some reason its being mounted on /mnt instead of /.
Code:
mounting /dev/mmcblk0p2 on /mnt failed: no such File or directory
I'm not sure why this is happening, but I suggest your try chrooting into your Slackware install on /dev/mmcblk0p2 and rerun eliloconfig.

Once you get a working slackware install then you can resolve the uefi menu problem.
ty for your reply. As far I could get in that kernel rescue shell, /dev/mmcblk0 was missing. I tried to create it even with the modules loaded but no luck.

Also I remember I did tried to run eliloconfig after chroot from the installer shell but couldnt get it to work either. (yes I did mounted proc and sys under chroot). By "coulnd't get it to work" I mean I gave me an error about the menu entry like I said in my first post, but that's all.

Later I also tried slackware-current live from usb, using the iso2usb.sh from Alienbob, screen went blank when selecting the first option and computer hang.

I wish I could provide more hardware info. If it were my hardware I would have trashed it, and since its going to be used for very simple tasks (just a web browser and a libreoffice package with a few documents) I ended up installing ubuntu on it : asked installer to wipe entire partitions and everything went fine. I'm not exactly an ubuntu fan.

even if I have solved my problem at hand I will not mark this as solved because I'm pretty sure I will run into a similar problem some day.

thank you again.

Last edited by rudymartinx; 04-05-2020 at 09:32 PM. Reason: fix minor mistake on efi partition mention
 
Old 04-06-2020, 04:25 AM   #9
business_kid
LQ Guru
 
Registered: Jan 2006
Location: Ireland
Distribution: Slackware, Slarm64 & Android
Posts: 17,418

Rep: Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590Reputation: 2590
Quote:
mounting /dev/mmcblk0p2 on /mnt failed: no such File or directory
In an install, / is the dvd, or usb is and it has a small basic system. Mounting on /mnt is good, because it can use commands like 'installpkg ROOT=/mnt <blah>' and run your install from there.
 
Old 04-06-2020, 02:55 PM   #10
rudymartinx
LQ Newbie
 
Registered: Apr 2020
Location: Argentina
Distribution: Slackware!
Posts: 17

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by business_kid View Post
In an install, / is the dvd, or usb is and it has a small basic system. Mounting on /mnt is good, because it can use commands like 'installpkg ROOT=/mnt <blah>' and run your install from there.
since I can't copy/paste another computer screen I had to type it by hand. There's a chance I could have made a mistake, but I believe that's indeed what I copied from the installed kernel messages during a booting test.

thank you anyway for the pointers.
 
Old 04-06-2020, 04:48 PM   #11
0XBF
Member
 
Registered: Nov 2018
Distribution: Slackware
Posts: 906

Rep: Reputation: 1095Reputation: 1095Reputation: 1095Reputation: 1095Reputation: 1095Reputation: 1095Reputation: 1095Reputation: 1095
The init script in slackware's initrd mounts the root device (the line passed by root=/dev/mmcblk0p2) on /mnt and then change_root's into the /mnt directory to finish booting the system from the init program on the disk. At least that's the way its supposed to work when booting with an initrd. I'm guessing since you don't have the proper modules loaded the mount command fails, and then it fails at finding init.

What happens when you try loading the huge kernel, without an initrd?

You could try that by changing your elilo.conf line to "image=vmlinuz-huge" and delete the "initrd=" line. If that boots and you still want to try the generic kernel then you could poke around with the /usr/share/mkinitrd_command_generator.sh script in slackware to find out what drivers you need to boot from an initrd.
 
Old 04-07-2020, 03:38 PM   #12
rudymartinx
LQ Newbie
 
Registered: Apr 2020
Location: Argentina
Distribution: Slackware!
Posts: 17

Original Poster
Rep: Reputation: Disabled
going to give it another try and see what happens.

Quote:
Originally Posted by 0XBF View Post
The init script in slackware's initrd mounts the root device (the line passed by root=/dev/mmcblk0p2) on /mnt and then change_root's into the /mnt directory to finish booting the system from the init program on the disk. At least that's the way its supposed to work when booting with an initrd. I'm guessing since you don't have the proper modules loaded the mount command fails, and then it fails at finding init.

What happens when you try loading the huge kernel, without an initrd?

You could try that by changing your elilo.conf line to "image=vmlinuz-huge" and delete the "initrd=" line. If that boots and you still want to try the generic kernel then you could poke around with the /usr/share/mkinitrd_command_generator.sh script in slackware to find out what drivers you need to boot from an initrd.
Thank you for your reply. What I understand from what are you telling me, the installed kernel is not the huge and that's new to me. Also I totally forgot/missed to mention the init error.

I'm about to give it another try to see what happens (at least I know I can make it work with ubuntu but I like more slackware's defects than ubuntu's virtues).-

thank you again.
 
Old 04-07-2020, 03:49 PM   #13
rudymartinx
LQ Newbie
 
Registered: Apr 2020
Location: Argentina
Distribution: Slackware!
Posts: 17

Original Poster
Rep: Reputation: Disabled
also: in case it doesn't work, I don't mind if I have to chroot the installed partition and build a kernel, but I would like to know which options I should look for.
 
Old 04-07-2020, 04:39 PM   #14
0XBF
Member
 
Registered: Nov 2018
Distribution: Slackware
Posts: 906

Rep: Reputation: 1095Reputation: 1095Reputation: 1095Reputation: 1095Reputation: 1095Reputation: 1095Reputation: 1095Reputation: 1095
Quote:
Originally Posted by rudymartinx View Post
Thank you for your reply. What I understand from what are you telling me, the installed kernel is not the huge and that's new to me. Also I totally forgot/missed to mention the init error.

I'm about to give it another try to see what happens (at least I know I can make it work with ubuntu but I like more slackware's defects than ubuntu's virtues).-

thank you again.
Usually slackware comes with the huge and generic kernel so you should have both in your /boot directory from the install. "vmlinuz" is just a link to one of these, usually the huge AFAIK. You could try leaving that as-is and removing the initrd line from your elilo.conf first. Huge kernel should have all modules built in so its good to try that first. If its still having troubles then you might have to go with the initrd to get the right drivers loaded first. I don't have any machines with "mmcblk" devices so I'm not 100% sure whats needs to be loaded for them.
 
Old 04-07-2020, 05:32 PM   #15
rudymartinx
LQ Newbie
 
Registered: Apr 2020
Location: Argentina
Distribution: Slackware!
Posts: 17

Original Poster
Rep: Reputation: Disabled
Thumbs up I MADE IT !!!!

Quote:
Originally Posted by 0XBF View Post
The init script in slackware's initrd mounts the root device (the line passed by root=/dev/mmcblk0p2) on /mnt and then change_root's into the /mnt directory to finish booting the system from the init program on the disk. At least that's the way its supposed to work when booting with an initrd. I'm guessing since you don't have the proper modules loaded the mount command fails, and then it fails at finding init.

What happens when you try loading the huge kernel, without an initrd?

You could try that by changing your elilo.conf line to "image=vmlinuz-huge" and delete the "initrd=" line. If that boots and you still want to try the generic kernel then you could poke around with the /usr/share/mkinitrd_command_generator.sh script in slackware to find out what drivers you need to boot from an initrd.
I did what you suggested but no luck (still the same errors with the huge.s, with or without initrd generated from the install disk). Scrolled up the kernel messages and I saw mmc_core being using insmod. Rescue shell shows it too and it also states its being used by sdhic, mmc_block (which I suspect its missing during boot) and sdhcpi_api.

Had to delete the grub efi section installed by ubuntu to be able to boot using efi shell because grub shell seems more obscure to me. New EFI entries shows on computer setup, I guess I will have to find a way to delete them later.

after many tries what I did was:

chroot /dev/mmcblk0p2 from install disk:

Quote:
mkdir linux
mount /dev/mmcblk0p2 /linux
mount /dev/mmcblk0p1 /linux/boot/efi
chroot linux
rebuild initrd including mmc_block which added mmc_core

copied /boot/vmlinuz-huge to efi slackware directory
modified elilo.conf as you suggested but included initrd:
image=vmlinuz-huge (copied from /boot)
initrd=initrd.gz (copied from /boot)

edit: by the time I have rebuild initrd there was an initrd-tree, I guess it was left by the installer, which missed to include the mentioned module.

now whats left is to solve the efi shell problem.

thank you!

Last edited by rudymartinx; 04-07-2020 at 05:34 PM. Reason: added comment about initrd
 
  


Reply

Tags
install, slackware-current


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
Slackware current install issue with mmcblk EFI partitions mshort007 Slackware - Installation 0 12-21-2018 02:47 AM
how to install linux mint side by side windows into an uefi machine without uefi partition valgalsan Linux - Newbie 2 11-03-2015 12:25 PM
Can't install LM 32bit with UEFI disabled on UEFI Asus X200MA laptop dblaisde Linux Mint 3 10-15-2015 05:37 AM
[SOLVED] kde current 13.37 86_64 - crash at finishing hua Slackware 8 03-31-2011 03:09 AM

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

All times are GMT -5. The time now is 08:40 PM.

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