Welcome!
Important information
-- Information on torrent hosting changes
-- Information on MX15/16 GPG Keys
-- Spectre and Meltdown vulnerabilities

News
-- Introducing our new Website
-- MX Linux on social media: here

Current releases
-- MX-18.1 Point Release release info here
-- Migration Information to MX-18 here
-- antiX-17.4 release info here

New users
-- Please read this first, and don't forget to add system and hardware information to posts!
-- Here are the Forum Rules

grub-efi not compatible?

User avatar
pinako
Forum Novice
Forum  Novice
Posts: 4
Joined: Sun Dec 30, 2018 1:39 pm

grub-efi not compatible?

#1

Post by pinako » Sun Dec 30, 2018 3:15 pm

Greetings! I recently discovered this excellent distro and I just installed it on my new computer. Thank you for a wonderful Linux desktop experience post-Ubuntu :)

I'm posting because I don't seem to be able to install grub-efi and some default MX packages at the same time. Observe: mx-apps depends on mx-bootrepair, which depends on grub-pc, which conflicts with grub-efi.

Code: Select all

# apt install mx-apps
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following additional packages will be installed:
  grub-pc grub-pc-bin mx-bootrepair
Suggested packages:
  desktop-base
The following packages will be REMOVED:
  grub-efi grub-efi-amd64
The following NEW packages will be installed:
  grub-pc grub-pc-bin mx-apps mx-bootrepair
0 upgraded, 4 newly installed, 2 to remove and 0 not upgraded.
Need to get 1,183 kB of archives.
After this operation, 3,714 kB of additional disk space will be used.
Do you want to continue? [Y/n]
Okay, how did we get here?

1. Set up a SSD and a HDD, both GPT-formatted, each with an ESP. Windows 10 is installed on /dev/nvme0n1p3 with bootloader on /dev/nvme0n1p1. A Windows recovery system is installed on /dev/sda1, which also doubles as an ESP (to allow other systems to be installed on /dev/sda for fun).

Code: Select all

Disk /dev/nvme0n1: 468862128 sectors, 223.6 GiB
Number  Start (sector)    End (sector)  Size       Code  Content
   1            2048          411647   200.0 MiB   EF00  ESP for Win10 and MX
   2          411648          444415   16.0 MiB    0C01  MSFT reserved
   3          444416       377931775   180.0 GiB   0700  Windows 10
   4       377931776       468860927   43.4 GiB    8300  MX Linux

Disk /dev/sda: 1953525168 sectors, 931.5 GiB
Number  Start (sector)    End (sector)  Size       Code  Content
   1            2048         1050623   512.0 MiB   EF00  ESP/Recovery
   2         3147776      1945110527   926.0 GiB   0700  NTFS data
   3      1945110528      1953523711   4.0 GiB     8200  MX Linux swap
2. Install MX Linux to /dev/nvme0n1p4 with bootloader on /dev/nvme0n1p1.

The installer does not allow installing GRUB to the ESP on /dev/nvme0n1p1. It allows installing to the ESP on /dev/sda1 or the MBR on /dev/nvme0n1, neither of which is desirable. Instead, we must chroot into the target rootfs and install grub-efi manually, which forces the removal of mx-bootrepair and mx-apps. Afterwards, mx-bootrepair from the installer is still confused:
screenie-esp.png
screenie-mbr-1.png
screenie-mbr-2.png
3. The installed OS functions well (modulo some drivers needing to be built/installed, but that's a different issue), except it lacks mx-bootrepair and mx-apps. We don't really care about mx-bootrepair, because if we could boot to the OS, the boot probably doesn't need repair. But without mx-apps, we may miss out on some updates to the MX applet collection. And the whole affair just doesn't feel polished.

Questions:
  1. Am I doing it wrong?
  2. Could the installer (and mx-bootrepair) be made to offer all the options for ESP installation?
  3. Could mx-bootrepair depend on grub-pc | grub-efi to allow either GRUB to be installed?
Thank you for considering ;)
You do not have the required permissions to view the files attached to this post.

User avatar
fehlix
Forum Veteran
Forum Veteran
Posts: 3136
Joined: Wed Apr 11, 2018 5:09 pm

Re: grub-efi not compatible?

#2

Post by fehlix » Sun Dec 30, 2018 3:31 pm

In addtion to the information you already send. Please do send inxi-system info
as the output of:

Code: Select all

inxi -Fxz
I have a similar (i hope) laptop, will see how to reproduce this...
:puppy:
Gigabyte Z77M-D3H, Intel Xeon E3-1240 V2 (Quad core), 32GB RAM,
GeForce GTX 770, Samsung SSD 850 EVO 500GB, Seagate Barracuda 4TB

User avatar
dolphin_oracle
Forum Veteran
Forum Veteran
Posts: 10880
Joined: Sun Dec 16, 2007 1:17 pm

Re: grub-efi not compatible?

#3

Post by dolphin_oracle » Sun Dec 30, 2018 4:31 pm

also please

Code: Select all

sudo parted -l
and

Code: Select all

sudo partition-info find-esp=/dev/nvme0n1
Last edited by dolphin_oracle on Sun Dec 30, 2018 4:38 pm, edited 1 time in total.
http://www.youtube.com/runwiththedolphin
lenovo ThinkPad T530 - MX-18
lenovo s21e - MX-18, antiX-17.3.1 (live-USB)
FYI: mx "test" repo is not the same thing as debian testing repo.

User avatar
dolphin_oracle
Forum Veteran
Forum Veteran
Posts: 10880
Joined: Sun Dec 16, 2007 1:17 pm

Re: grub-efi not compatible?

#4

Post by dolphin_oracle » Sun Dec 30, 2018 4:33 pm

dolphin_oracle wrote:
Sun Dec 30, 2018 4:31 pm
also please

Code: Select all

sudo parted -l 
and

Code: Select all

sudo partition-info find-esp=/dev/nvme0n1

also we have the grub efi *bin files installed, which will handle the efi work. the issue for you seems to be that we can't find the esp on your nvme device.
http://www.youtube.com/runwiththedolphin
lenovo ThinkPad T530 - MX-18
lenovo s21e - MX-18, antiX-17.3.1 (live-USB)
FYI: mx "test" repo is not the same thing as debian testing repo.

User avatar
Paul..
Forum Guide
Forum Guide
Posts: 2524
Joined: Sun Mar 18, 2007 6:34 pm

Re: grub-efi not compatible?

#5

Post by Paul.. » Sun Dec 30, 2018 4:41 pm

Why have 2 ESPs? Is there a reason for that?

Asus Prime X470-Pro | AMD Ryzen 5 1400 (8 threads)
16 Gig DDR4 3000 | nVidia - GeForce GTX 750 Ti
Samsung 970 NVMe SSD | 860 500GB SSD

User avatar
pinako
Forum Novice
Forum  Novice
Posts: 4
Joined: Sun Dec 30, 2018 1:39 pm

Re: grub-efi not compatible?

#6

Post by pinako » Sun Dec 30, 2018 4:48 pm

Thank you for entertaining my questions.
fehlix wrote:
Sun Dec 30, 2018 3:31 pm
Please do send inxi-system info
Neat. Didn't know this tool existed. Thank you.

Code: Select all

# inxi -Fxz
System:    Host: ginger Kernel: 4.19.0-1-amd64 x86_64 bits: 64 compiler: gcc v: 6.3.0 
           Desktop: Xfce 4.12.3 Distro: MX-18_x64 Continuum Dec 20  2018 
           base: Debian GNU/Linux 9 (stretch) 
Machine:   Type: Desktop System: HP product: HP Slim Desktop 290-p0xxx v: N/A serial: <filter> 
           Mobo: HP model: 843F v: 00 serial: <filter> UEFI: AMI v: F.12 date: 08/06/2018 
Battery:   Device-1: hidpp_battery_0 model: Logitech Wireless Mouse M325 charge: Normal 
           status: Discharging 
CPU:       Topology: 6-Core model: Intel Core i5-8400 bits: 64 type: MCP arch: Kaby Lake rev: A 
           L2 cache: 9216 KiB 
           flags: lm nx pae sse sse2 sse3 sse4_1 sse4_2 ssse3 vmx bogomips: 33696 
           Speed: 800 MHz min/max: 800/4000 MHz Core speeds (MHz): 1: 800 2: 800 3: 800 4: 801 
           5: 800 6: 800 
Graphics:  Device-1: Intel vendor: Hewlett-Packard driver: i915 v: kernel bus ID: 00:02.0 
           Display: server: X.Org 1.19.2 driver: modesetting unloaded: fbdev,vesa 
           resolution: 1920x1080~60Hz 
           OpenGL: renderer: Mesa DRI Intel UHD Graphics 630 (Coffeelake 3x8 GT2) 
           v: 4.5 Mesa 18.2.6 direct render: Yes 
Audio:     Device-1: Intel vendor: Hewlett-Packard driver: snd_hda_intel v: kernel 
           bus ID: 00:1f.3 
           Sound Server: ALSA v: k4.19.0-1-amd64 
Network:   Device-1: Realtek RTL8111/8168/8411 PCI Express Gigabit Ethernet 
           vendor: Hewlett-Packard driver: r8169 v: kernel port: 4000 bus ID: 01:00.0 
           IF: eth0 state: down mac: <filter> 
           Device-2: Realtek vendor: Hewlett-Packard driver: rtl8821ce v: N/A port: 3000 
           bus ID: 02:00.0 
           IF: wlan0 state: up mac: <filter> 
Drives:    Local Storage: total: 1.13 TiB used: 18.54 GiB (1.6%) 
           ID-1: /dev/nvme0n1 vendor: A-Data model: SX8200NP size: 223.57 GiB 
           ID-2: /dev/sda vendor: Seagate model: ST1000DM003-1SB102 size: 931.51 GiB temp: 31 C 
Partition: ID-1: / size: 42.68 GiB used: 4.98 GiB (11.7%) fs: ext4 dev: /dev/nvme0n1p4 
           ID-2: swap-1 size: 4.01 GiB used: 0 KiB (0.0%) fs: swap dev: /dev/sda3 
Sensors:   System Temperatures: cpu: 28.0 C mobo: N/A 
           Fan Speeds (RPM): N/A 
Info:      Processes: 233 Uptime: 2h 25m Memory: 7.66 GiB used: 1.45 GiB (18.9%) Init: SysVinit 
           runlevel: 5 Compilers: gcc: 6.3.0 Shell: bash v: 4.4.12 inxi: 3.0.29
dolphin_oracle wrote:
Sun Dec 30, 2018 4:31 pm
also please

Code: Select all

sudo fdisk -l
and

Code: Select all

sudo partition-info find-esp=/dev/nvme0n1

Code: Select all

# fdisk -l
Disk /dev/nvme0n1: 223.6 GiB, 240057409536 bytes, 468862128 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: 9D92A234-8C75-496E-8057-757E62484933

Device             Start       End   Sectors  Size Type
/dev/nvme0n1p1      2048    411647    409600  200M EFI System
/dev/nvme0n1p2    411648    444415     32768   16M Microsoft reserved
/dev/nvme0n1p3    444416 377931775 377487360  180G Microsoft basic data
/dev/nvme0n1p4 377931776 468860927  90929152 43.4G Linux filesystem


Disk /dev/sda: 931.5 GiB, 1000204886016 bytes, 1953525168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: gpt
Disk identifier: 16F308C9-46E2-4C68-A976-6737DDC7A724

Device          Start        End    Sectors  Size Type
/dev/sda1        2048    1050623    1048576  512M EFI System
/dev/sda2     3147776 1945110527 1941962752  926G Microsoft basic data
/dev/sda3  1945110528 1953523711    8413184    4G Linux swap

Code: Select all

# parted -l
Model: ATA ST1000DM003-1SB1 (scsi)
Disk /dev/sda: 1000GB
Sector size (logical/physical): 512B/4096B
Partition Table: gpt
Disk Flags: 

Number  Start   End     Size    File system     Name                  Flags
 1      1049kB  538MB   537MB   fat32           EFI System            boot, esp
 2      1612MB  996GB   994GB   ntfs            Microsoft basic data  msftdata
 3      996GB   1000GB  4308MB  linux-swap(v1)  Linux swap


Model: Unknown (unknown)
Disk /dev/nvme0n1: 240GB
Sector size (logical/physical): 512B/512B
Partition Table: gpt
Disk Flags: 

Number  Start   End    Size    File system  Name                  Flags
 1      1049kB  211MB  210MB   fat16        EFI System            boot, esp
 2      211MB   228MB  16.8MB               Microsoft reserved    msftres
 3      228MB   194GB  193GB   ntfs         Microsoft basic data  msftdata
 4      194GB   240GB  46.6GB  ext2         Linux system

Code: Select all

# partition-info find-esp=/dev/nvme0n1
nvme0n1p1
dolphin_oracle wrote:
Sun Dec 30, 2018 4:33 pm
also we have the grub efi *bin files installed, which will handle the efi work. the issue for you seems to be that we can't find the esp on your nvme device.
Yes. The /boot/efi/EFI/mx/grubx64.efi file is attached. I gzipped it because the forum would not accept a *.efi file.
Paul.. wrote:
Sun Dec 30, 2018 4:41 pm
Why have 2 ESPs?
  • The recovery tool was designed to be written to a USB stick, so it's a FAT partition containing the ESP boot program.
  • I also want to experiment with the second disk without interfering with the first one.
You do not have the required permissions to view the files attached to this post.

User avatar
dolphin_oracle
Forum Veteran
Forum Veteran
Posts: 10880
Joined: Sun Dec 16, 2007 1:17 pm

Re: grub-efi not compatible?

#7

Post by dolphin_oracle » Sun Dec 30, 2018 5:05 pm

I'm going to suggest something a little nutty but bear with me.

Our installer uses the first esp that it finds. In your case, that is apparently sda.

I suggest temporarily removing the ESP flag from the partition you do not want to use and then running the installer. the only ESP partition available at that point will be the one you desire.

After install is finished, put the ESP flag back on the other partition. It won't affect the grub installation.
http://www.youtube.com/runwiththedolphin
lenovo ThinkPad T530 - MX-18
lenovo s21e - MX-18, antiX-17.3.1 (live-USB)
FYI: mx "test" repo is not the same thing as debian testing repo.

User avatar
fehlix
Forum Veteran
Forum Veteran
Posts: 3136
Joined: Wed Apr 11, 2018 5:09 pm

Re: grub-efi not compatible?

#8

Post by fehlix » Sun Dec 30, 2018 5:09 pm

pinako wrote:
Sun Dec 30, 2018 3:15 pm

Code: Select all

# apt install mx-apps
The following NEW packages will be installed:
  grub-pc grub-pc-bin mx-apps mx-bootrepair
Still gathering info's. What I don't understand is, why you have those above packages as new packages,
they all are by default installed already.
What certainly wrong is this:

Code: Select all

The following packages will be REMOVED:
  grub-efi grub-efi-amd64
Not the removal is wrong, but that you have this packages installed at all.
So I assume, you have borked, your grub/efi setup yourself by installing those in the first place,
which than removed those other needed grub-packages
These grub packages are needed in MX18:

Code: Select all

grub-common - GRand Unified Bootloader (common files)
grub-efi-amd64-bin - GRand Unified Bootloader, version 2 (EFI-AMD64 binaries)
grub-efi-ia32-bin - GRand Unified Bootloader, version 2 (EFI-IA32 binaries)
grub-pc - GRand Unified Bootloader, version 2 (PC/BIOS version)
grub-pc-bin - GRand Unified Bootloader, version 2 (PC/BIOS binaries)
grub2-common - GRand Unified Bootloader (common files for version 2)
:puppy:
Gigabyte Z77M-D3H, Intel Xeon E3-1240 V2 (Quad core), 32GB RAM,
GeForce GTX 770, Samsung SSD 850 EVO 500GB, Seagate Barracuda 4TB

User avatar
pinako
Forum Novice
Forum  Novice
Posts: 4
Joined: Sun Dec 30, 2018 1:39 pm

Re: grub-efi not compatible?

#9

Post by pinako » Sun Dec 30, 2018 5:26 pm

dolphin_oracle wrote:
Sun Dec 30, 2018 5:05 pm
I'm going to suggest something a little nutty but bear with me.

Our installer uses the first esp that it finds. In your case, that is apparently sda.

I suggest temporarily removing the ESP flag from the partition you do not want to use and then running the installer. the only ESP partition available at that point will be the one you desire.

After install is finished, put the ESP flag back on the other partition. It won't affect the grub installation.
Thank you for the insight, and a good idea. I think I'll try it with the mx-bootrepair tool first.
fehlix wrote:
Sun Dec 30, 2018 5:09 pm
pinako wrote:
Sun Dec 30, 2018 3:15 pm

Code: Select all

# apt install mx-apps
The following NEW packages will be installed:
  grub-pc grub-pc-bin mx-apps mx-bootrepair
Still gathering info's. What I don't understand is, why you have those above packages as new packages,
they all are by default installed already.
What certainly wrong is this:

Code: Select all

The following packages will be REMOVED:
  grub-efi grub-efi-amd64
Not the removal is wrong, but that you have this packages installed at all.
So I assume, you have borked, your grub/efi setup yourself by installing those in the first place,
which than removed those other needed grub-packages
These grub packages are needed in MX18:

Code: Select all

grub-common - GRand Unified Bootloader (common files)
grub-efi-amd64-bin - GRand Unified Bootloader, version 2 (EFI-AMD64 binaries)
grub-efi-ia32-bin - GRand Unified Bootloader, version 2 (EFI-IA32 binaries)
grub-pc - GRand Unified Bootloader, version 2 (PC/BIOS version)
grub-pc-bin - GRand Unified Bootloader, version 2 (PC/BIOS binaries)
grub2-common - GRand Unified Bootloader (common files for version 2)
You're right. I could not install GRUB correctly using the installer, so I needed to chroot into the target rootfs and install grub-efi. At this point, grub-pc, mx-bootrepair, and mx-apps had already been installed. Installing grub-efi forced these other packages to be removed. I broke the default set of packages, but achieved a booting system.

Should I have installed only grub-efi-amd64-bin instead? It seems that grub-pc would coexist peacefully with grub-efi-amd64-bin, and grub-efi and grub-efi-amd64 could be removed without breaking the boot.

User avatar
dolphin_oracle
Forum Veteran
Forum Veteran
Posts: 10880
Joined: Sun Dec 16, 2007 1:17 pm

Re: grub-efi not compatible?

#10

Post by dolphin_oracle » Sun Dec 30, 2018 5:29 pm

grub-efi-amd64-bin and grub-efi-ia32-bin are preinstalled
http://www.youtube.com/runwiththedolphin
lenovo ThinkPad T530 - MX-18
lenovo s21e - MX-18, antiX-17.3.1 (live-USB)
FYI: mx "test" repo is not the same thing as debian testing repo.

Post Reply

Return to “Installation”