GRUB broken on newly updated MX-21

Report Bugs, Issues and non- package Requests
Message
Author
theprofa325
Posts: 21
Joined: Sat Jan 11, 2020 9:13 am

GRUB broken on newly updated MX-21

#1 Post by theprofa325 »

I upgraded my daily driver desktop MX-21 system with synaptic and it broke the NVidia graphics. It would boot but only to a text screen. Then trying to follow web instructions to fix this, I somehow broke GRUB and now it will not boot at all (stops with "grub rescue>" prompt. I can boot and run fine with an MX-21 live usb.



MX Boot Repair cannot seem to reinstall GRUB and get me running again.
I think all the help I need is detailed instructions to get MX Boot Repair to successfully reinstall a bootable GRUB.

Thank you for creating/maintaining MX and for any assistance with this problem.


The hard disk is mountable and readable from the live-usb system. Here is its partition table:

Code: Select all

Disk /dev/sda: 931.51 GiB, 1000204886016 bytes, 1953525168 sectors
Disk model: CT1000MX500SSD1 
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: dos
Disk identifier: 0xfc6cd71c

Device     Boot      Start        End    Sectors   Size Id Type
/dev/sda1  *          2048    1953791    1951744   953M 83 Linux
/dev/sda2          1955838 1907783679 1905827842 908.8G  5 Extended
/dev/sda3       1907783680 1953523711   45740032  21.8G 82 Linux swap / Solaris
/dev/sda5        126955520  142579711   15624192   7.5G ef EFI (FAT-12/16/32)
/dev/sda6        142581760 1907363839 1764782080 841.5G 83 Linux
/dev/sda7          1957888  126953471  124995584  59.6G 83 Linux

Partition 2 does not start on physical sector boundary.
Partition table entries are not in disk order.




I post below the system information I can get, considering that in the live-usb system neither lspci nor Quick System Info works.

attempting to boot from HD:

Code: Select all

GRUB loading.
Welcome to GRUB!

error: file `grub/i386-pc/normal.mod not found.
grub rescue> _

=============================================================
Running from mx live usb (perfectly good running system):

Code: Select all

$ more /etc/mx-version 
MX-21.2.1_x64 Wildflower September 18, 2022
=============================================================
Attempted to invoke Quick System Info from menu in live-usb session, got this error:

Code: Select all

PerlIO.pm did not return a true value at /usr/local/bin/inxi line 4037.
BEGIN failed--compilation aborted.

Boot Mode: BIOS (legacy, CSM, MBR)
=============================================================
Attempted to use lspci in live-usb session for system information:

Code: Select all

$ sudo lspci
Bus error
$ lspci -A linux-proc
lspci: I/O error at /usr/share/misc/pci.ids, line 0


$ sudo lspci -A intel-conf1
Bus error
demo@mx1:~
$ sudo lspci -A intel-conf2
Bus error
demo@mx1:~
$ sudo lspci -A linux-sysfs
Bus error
demo@mx1:~
$ sudo lspci -A linux-proc
Bus error
=============================================================
Getting system info in live-usb session from /proc:

Code: Select all

$ more /proc/bus/pci/input/devices
I: Bus=0003 Vendor=046d Product=400a Version=0111
N: Name="Logitech M325"
P: Phys=usb-0000:00:1a.0-1.2/input2:1
S: Sysfs=/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.2/1-1.2:1.2/0003:046D:C52B.0006/0003:046D:400A.0009/input/input10
U: Uniq=400a-61-8e-ee-30
H: Handlers=mouse0 event0 
B: PROP=0
B: EV=17
B: KEY=ffff0000 0 0 0 0
B: REL=1943
B: MSC=10

I: Bus=0003 Vendor=046d Product=401b Version=0111
N: Name="Logitech M215 2nd Gen"
P: Phys=usb-0000:00:1a.0-1.1/input2:1
S: Sysfs=/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.1/1-1.1:1.2/0003:046D:C52B.0003/0003:046D:401B.0007/input/input11
U: Uniq=401b-f6-42-75-31
H: Handlers=mouse1 event1 
B: PROP=0
B: EV=17
B: KEY=ffff0000 0 0 0 0
B: REL=1943
B: MSC=10

I: Bus=0003 Vendor=046d Product=4016 Version=0111
N: Name="Logitech K330"
P: Phys=usb-0000:00:1a.0-1.1/input2:2
S: Sysfs=/devices/pci0000:00/0000:00:1a.0/usb1/1-1/1-1.1/1-1.1:1.2/0003:046D:C52B.0003/0003:046D:4016.0008/input/input12
U: Uniq=4016-ab-61-ac-c5
H: Handlers=sysrq kbd leds event2 
B: PROP=0
B: EV=12001f
B: KEY=3f000307ff 0 0 483ffff17aff32d bfd4444600000000 1 130ff38b17d007 ffff7bfad941dfff ffbeffdfffefffff fffffffffffffffe
B: REL=1040
B: ABS=100000000
B: MSC=10
B: LED=1f

I: Bus=0019 Vendor=0000 Product=0001 Version=0000
N: Name="Power Button"
P: Phys=PNP0C0C/button/input0
S: Sysfs=/devices/LNXSYSTM:00/LNXSYBUS:00/PNP0C0C:00/input/input13
U: Uniq=
H: Handlers=kbd event3 
B: PROP=0
B: EV=3
B: KEY=10000000000000 0

I: Bus=0019 Vendor=0000 Product=0001 Version=0000
N: Name="Power Button"
P: Phys=LNXPWRBN/button/input0
S: Sysfs=/devices/LNXSYSTM:00/LNXPWRBN:00/input/input14
U: Uniq=
H: Handlers=kbd event4 
B: PROP=0
B: EV=3
B: KEY=10000000000000 0

I: Bus=0000 Vendor=0000 Product=0000 Version=0000
N: Name="HDA NVidia HDMI/DP,pcm=3"
P: Phys=ALSA
S: Sysfs=/devices/pci0000:00/0000:00:01.0/0000:01:00.1/sound/card1/input15
U: Uniq=
H: Handlers=event5 
B: PROP=0
B: EV=21
B: SW=140

I: Bus=0000 Vendor=0000 Product=0000 Version=0000
N: Name="HDA NVidia HDMI/DP,pcm=7"
P: Phys=ALSA
S: Sysfs=/devices/pci0000:00/0000:00:01.0/0000:01:00.1/sound/card1/input16
U: Uniq=
H: Handlers=event6 
B: PROP=0
B: EV=21
B: SW=140

I: Bus=0000 Vendor=0000 Product=0000 Version=0000
N: Name="HDA NVidia HDMI/DP,pcm=8"
P: Phys=ALSA
S: Sysfs=/devices/pci0000:00/0000:00:01.0/0000:01:00.1/sound/card1/input17
U: Uniq=
H: Handlers=event7 
B: PROP=0
B: EV=21
B: SW=140

I: Bus=0000 Vendor=0000 Product=0000 Version=0000
N: Name="HDA NVidia HDMI/DP,pcm=9"
P: Phys=ALSA
S: Sysfs=/devices/pci0000:00/0000:00:01.0/0000:01:00.1/sound/card1/input18
U: Uniq=
H: Handlers=event8 
B: PROP=0
B: EV=21
B: SW=140

I: Bus=0000 Vendor=0000 Product=0000 Version=0000
N: Name="HDA NVidia HDMI/DP,pcm=10"
P: Phys=ALSA
S: Sysfs=/devices/pci0000:00/0000:00:01.0/0000:01:00.1/sound/card1/input19
U: Uniq=
H: Handlers=event9 
B: PROP=0
B: EV=21
B: SW=140

I: Bus=0000 Vendor=0000 Product=0000 Version=0000
N: Name="HDA NVidia HDMI/DP,pcm=11"
P: Phys=ALSA
S: Sysfs=/devices/pci0000:00/0000:00:01.0/0000:01:00.1/sound/card1/input20
U: Uniq=
H: Handlers=event10 
B: PROP=0
B: EV=21
B: SW=140

I: Bus=0000 Vendor=0000 Product=0000 Version=0000
N: Name="HDA Intel PCH Front Mic"
P: Phys=ALSA
S: Sysfs=/devices/pci0000:00/0000:00:1b.0/sound/card0/input21
U: Uniq=
H: Handlers=event11 
B: PROP=0
B: EV=21
B: SW=10

I: Bus=0000 Vendor=0000 Product=0000 Version=0000
N: Name="HDA Intel PCH Rear Mic"
P: Phys=ALSA
S: Sysfs=/devices/pci0000:00/0000:00:1b.0/sound/card0/input22
U: Uniq=
H: Handlers=event12 
B: PROP=0
B: EV=21
B: SW=10

I: Bus=0000 Vendor=0000 Product=0000 Version=0000
N: Name="HDA Intel PCH Line Out"
P: Phys=ALSA
S: Sysfs=/devices/pci0000:00/0000:00:1b.0/sound/card0/input23
U: Uniq=
H: Handlers=event13 
B: PROP=0
B: EV=21
B: SW=40

I: Bus=0000 Vendor=0000 Product=0000 Version=0000
N: Name="HDA Intel PCH Front Headphone"
P: Phys=ALSA
S: Sysfs=/devices/pci0000:00/0000:00:1b.0/sound/card0/input24
U: Uniq=
H: Handlers=event14 
B: PROP=0
B: EV=21
B: SW=4

I: Bus=0003 Vendor=0000 Product=0000 Version=0004
N: Name="ACPI Virtual Keyboard Device"
P: Phys=
S: Sysfs=/devices/virtual/input/input25
U: Uniq=
H: Handlers=sysrq kbd event15 rfkill 
B: PROP=0
B: EV=3
B: KEY=ffffffffffffffff ffffffffffffffff ffffffffffffffff fffffffffffffffe
==============================================================
more sytem information in live-usb session:

Code: Select all

more /proc/bus/pci/devices
0000	80860c00	0	               0	               0	               0	               0	               0	               0	               0	               0	               0	               0	               0	               0	               0	               0	hsw_uncore
0008	80860c01	19	               0	               0	               0	               0	               0	               0	               0	               0	               0	               0	               0	               0	               0	               0	pcieport
00a0	80868c31	1d	        f7120004	               0	               0	               0	               0	               0	               0	           10000	               0	               0	               0	               0	               0	               0	xhci_hcd
00b0	80868c3a	1e	        f713c004	               0	               0	               0	               0	               0	               0	              10	               0	               0	               0	               0	               0	               0	mei_me
00c8	8086153a	1f	        f7100000	        f7139000	            f041	               0	               0	               0	               0	           20000	            1000	              20	               0	               0	               0	               0	e1000e
00d0	80868c2d	10	        f7138000	               0	               0	               0	               0	               0	               0	             400	               0	               0	               0	               0	               0	               0	ehci-pci
00d8	80868c20	20	        f7130004	               0	               0	               0	               0	               0	               0	            4000	               0	               0	               0	               0	               0	               0	snd_hda_intel
00e0	80868c10	1a	               0	               0	               0	               0	               0	               0	               0	               0	               0	               0	               0	               0	               0	               0	pcieport
00e1	80868c12	1b	               0	               0	               0	               0	               0	               0	               0	               0	               0	               0	               0	               0	               0	               0	pcieport
00e8	80868c26	17	        f7137000	               0	               0	               0	               0	               0	               0	             400	               0	               0	               0	               0	               0	               0	ehci-pci
00f8	80868c4e	0	               0	               0	               0	               0	               0	               0	               0	               0	               0	               0	               0	               0	               0	               0	lpc_ich
00fa	80868c02	1c	            f091	            f081	            f071	            f061	            f021	        f7136000	               0	               8	               4	               8	               4	              20	             800	               0	ahci
00fb	80868c22	12	        f7135004	               0	               0	               0	            f001	               0	               0	             100	               0	               0	               0	              20	               0	               0	i801_smbus
0100	10de11c4	21	        f6000000	        e800000c	               0	        f000000c	               0	            e001	           c0002	         1000000	         8000000	               0	         2000000	               0	              80	           20000	nouveau
0101	10de0e0b	11	        f7080000	               0	               0	               0	               0	               0	               0	            4000	               0	               0	               0	               0	               0	               0	snd_hda_intel
0300	104c8240	0	               0	               0	               0	               0	               0	               0	               0	               0	               0	               0	               0	               0	               0	               0	

Huckleberry Finn

Re: GRUB broken on newly updated MX-21

#2 Post by Huckleberry Finn »

Since it's:

Boot Mode: BIOS (legacy, CSM, MBR)

Select MBR when reinstalling Grub on live session with MX Boot Repair.

Location: sda

Select /boot (or /root) location: (Where MX is ... sda6 or 7 .. )


Just btw. put the boot flag on MX's partition, or on the ESP partition together with the esp flag.

User avatar
fehlix
Developer
Posts: 12932
Joined: Wed Apr 11, 2018 5:09 pm

Re: GRUB broken on newly updated MX-21

#3 Post by fehlix »

theprofa325 wrote: Fri Oct 14, 2022 1:22 pm I upgraded my daily driver desktop MX-21 system with synaptic and it broke the NVidia graphics. It would boot but only to a text screen. Then trying to follow web instructions to fix this, I somehow broke GRUB and now it will not boot at all (stops with "grub rescue>" prompt. I can boot and run fine with an MX-21 live usb.



MX Boot Repair cannot seem to reinstall GRUB and get me running again.
I think all the help I need is detailed instructions to get MX Boot Repair to successfully reinstall a bootable GRUB.
* Depends what you have already done, b/c "cannot seem to reinstall GRUB" is not much info. Any error message?

* Also, you have not mentioned what version and architecture are involved. There seems to be an EFI partition on a mbr/dos drive, which is rather unusual, but doable. What BOOT mode are you booting in UEFI or BIOS mode on the installed system ( the LIVE USB shows BIOS boot mode)

* the error message on QSI perl related is also a bit unusual, is this a customized ISO/USB ?
or can you get latest ISO

* Are you able to use "Chroot Rescue Scan" tool found in the menu,
and try to get a chroot-terminal on the installed system-
If yes, try to fix pending any configuration of packages like

Code: Select all

dpkg --configure -a 
With chroot you could:
* depending now on what boot mode UEFI or BIOS are involved reinstall GRUB
* fix NVIDIA , either reinstal or remve first and try with build in nouveau first
...
but give some details first, before going into much different directions.

theprofa325
Posts: 21
Joined: Sat Jan 11, 2020 9:13 am

Re: GRUB broken on newly updated MX-21

#4 Post by theprofa325 »

...amazingly quick response, thanks.

I tried first what Huckleberry suggested. Now instead of what I reported before when attempting to boot from HD:

Code: Select all

GRUB loading.
Welcome to GRUB!

error: file `grub/i386-pc/normal.mod not found.
grub rescue> _
I now get :

Code: Select all

GNU GRUB version 2.06-3~deb11u1

Minimal BASH-like line editing is supported.  For the first word, TAB
lists possible command completions.  Anywhere else TAB lists possible
device or file conpletions.

grub>
In answer to Fehlix's questions:
=======================================
* Depends what you have already done, b/c "cannot seem to reinstall GRUB" is not much info. Any error message?

The MX Boot Repair tool does not give any error message, it reports success. However the system is not bootable. I have gone through the tool serially trying most of the options. It appears that it installs a version of GRUB that requires files that are not present on the installed system.

* Also, you have not mentioned what version and architecture are involved. There seems to be an EFI partition on a mbr/dos drive, which is rather unusual, but doable. What BOOT mode are you booting in UEFI or BIOS mode

Sorry but I don't understand the first part of this question. Version and architecture of what?
Using the chroot scan tool, I can see that the installed system is:

Code: Select all

more /etc/mxversion  
MX-21-x64 Wildflower Oct. 20, 2021

I am a bit ashamed to admit that I don't know whether the thing was booting UEFI or BIOS- I simply did a vanilla install of MX-21 from live usb (over my previous MX-19) and it is what it is. The hardware is a 2014 Dell Optiplex 9080 with a new-ish 1 TB SSD, if that gives any indication.

* the error message on QSI perl related is also a bit unusual, is this a customized ISO/USB ?
or can you get latest ISO

This USB was produced with the MX usb-making utility from a freshly downloaded MX ISO. No customizations, no persistence.

* Are you able to use "Chroot Rescue Scan" tool found in the menu,

I can access it and it finds my install on the HD. Entering the command you suggest (dpkg --configure -a) completes silently- no output at all.

Hoping to get this fixed, thanks for any more help.

Huckleberry Finn

Re: GRUB broken on newly updated MX-21

#5 Post by Huckleberry Finn »

Just chroot as you did and:

Code: Select all

grub-install /dev/sda

User avatar
fehlix
Developer
Posts: 12932
Joined: Wed Apr 11, 2018 5:09 pm

Re: GRUB broken on newly updated MX-21

#6 Post by fehlix »

Ah .. ok and oops.., the architecture was already shown in /etc/mx-version as amd64 64 bit
and also indicate it is Xfce version not KDE or fluxbox.
So now let try manual fix the grub-loader:
go into chroot again from live USB make sure/verify /dev/sda is still you boot device
so run

Code: Select all

lsblk -f

b/c the kernel may have reordered/reassigned different names due the the LiveUSB is plugged in.
Now, do install the GRUB loader into MBR:

Code: Select all

sudo grub-install --target=i386-pc  --recheck  /dev/sda
make sure if /dev/sda is show als the internal partition other adjust accordingly to the lsblk -f output.
post any output or errors.
and

Code: Select all

update-grub
Next run

Code: Select all

apt update
and

Code: Select all

apt full-upgrade
you may see some further updates.
Let's see so far any issue ...

+++EDIT+++
OK, and if there is a update of grub shown please run again:
in chroot'ed terminal

Code: Select all

grub-install --target=i386-pc  --recheck  /dev/sda
and

Code: Select all

update-grub
* in case you get any error message pleas post.
* also if you do still see grub-rescue prompt when booted do try this within chroot:

Code: Select all

grub-install --target=i386-pc  --recheck --modules=normal /dev/sda
this would (hopefully) make normal.mod loaded early.

theprofa325
Posts: 21
Joined: Sat Jan 11, 2020 9:13 am

Re: GRUB broken on newly updated MX-21

#7 Post by theprofa325 »

Alas, still no joy. Still boots to the grub> prompt.

I did the grub reinstall and update in chroot:

Code: Select all


chroot> sudo grub-install --target=i386-pc --recheck /dev/sdb
Installing for i386-pc platform.
Installation finished. No error reported.

(MX_21_Wildflower_) Sat Oct 15 06:07:44 /
chroot> update-grub
Generating grub configuration file ...
Warning: os-prober will be executed to detect other bootable partitions.
Its output will be used to detect bootable binaries on them and create new boot entries.
done

Then the update and upgrade. During upgrade received some suspicious messages that I don't know enough to interpret:

Code: Select all


Preconfiguring packages ...
(Reading database ... 536156 files and directories currently installed.)
Removing linux-headers-5.10.0-14-amd64 (5.10.113-1) ...
Removing linux-image-5.10.0-14-amd64 (5.10.113-1) ...
/etc/kernel/prerm.d/dkms:
dkms: removing: 8812au 4.2.2 (5.10.0-14-amd64) (x86_64)

-------- Uninstall Beginning --------
Module:  8812au
Version: 4.2.2
Kernel:  5.10.0-14-amd64 (x86_64)
-------------------------------------

Status: Before uninstall, this module version was ACTIVE on this kernel.

8812au.ko:
 - Uninstallation
   - Deleting from: /lib/modules/5.10.0-14-amd64/kernel/drivers/net/wireless/
 - Original module
   - No original module was found for this module on this kernel.
   - Use the dkms install command to reinstall any previous module version.

depmod....

DKMS: uninstall completed.
dkms: removing: broadcom-sta 6.30.223.271 (5.10.0-14-amd64) (x86_64)

-------- Uninstall Beginning --------
Module:  broadcom-sta
Version: 6.30.223.271
Kernel:  5.10.0-14-amd64 (x86_64)
-------------------------------------

Status: Before uninstall, this module version was ACTIVE on this kernel.

wl.ko:
 - Uninstallation
   - Deleting from: /lib/modules/5.10.0-14-amd64/updates/dkms/
 - Original module
   - No original module was found for this module on this kernel.
   - Use the dkms install command to reinstall any previous module version.

depmod...

Warning: Unable to find an initial ram disk that I know how to handle.
Will not try to make an initrd.

DKMS: uninstall completed.
dkms: removing: rtl8821ce 5.5.2.1 (5.10.0-14-amd64) (x86_64)

-------- Uninstall Beginning --------
Module:  rtl8821ce
Version: 5.5.2.1
Kernel:  5.10.0-14-amd64 (x86_64)
-------------------------------------

Status: Before uninstall, this module version was ACTIVE on this kernel.

rtl8821ce.ko:
 - Uninstallation
   - Deleting from: /lib/modules/5.10.0-14-amd64/updates/
 - Original module
   - No original module was found for this module on this kernel.
   - Use the dkms install command to reinstall any previous module version.

/etc/modprobe.d/dkms.conf: removed 'blacklist rtw88_8821ce'
depmod...

DKMS: uninstall completed.
dkms: removing: rtl8821cu 5.4.1 (5.10.0-14-amd64) (x86_64)

-------- Uninstall Beginning --------
Module:  rtl8821cu
Version: 5.4.1
Kernel:  5.10.0-14-amd64 (x86_64)
-------------------------------------

Status: Before uninstall, this module version was ACTIVE on this kernel.

8821cu.ko:
 - Uninstallation
   - Deleting from: /lib/modules/5.10.0-14-amd64/kernel/drivers/net/wireless/realtek/rtl8821cu/
 - Original module
   - No original module was found for this module on this kernel.
   - Use the dkms install command to reinstall any previous module version.

depmod...

DKMS: uninstall completed.
W: Last kernel image has been removed, so removing the default symlinks
/etc/kernel/postrm.d/initramfs-tools:
update-initramfs: Deleting /boot/initrd.img-5.10.0-14-amd64
/etc/kernel/postrm.d/zz-update-grub:
Generating grub configuration file ...
Warning: os-prober will be executed to detect other bootable partitions.
Its output will be used to detect bootable binaries on them and create new boot entries.
done

During the update, grub was upgraded and gave suspicious messages:

Code: Select all

Installing for i386-pc platform.
grub-install: warning: File system `ext2' doesn't support embedding.
grub-install: warning: Embedding is not possible.  GRUB can only be installed in this setup by using
 blocklists.  However, blocklists are UNRELIABLE and their use is discouraged..
Installation finished. No error reported.
Generating grub configuration file ...
Warning: os-prober will be executed to detect other bootable partitions.
Its output will be used to detect bootable binaries on them and create new boot entries.
done
Setting up dbus-user-session (1.12.24-0+deb11u1) ...
Setting up libreoffice-style-sifr (1:7.0.4-4+deb11u4) ...
Setting up libuno-cppu3 (1:7.0.4-4+deb11u4) ...


Processing triggers for hicolor-icon-theme (0.17-2) ...


After upgrade I did the grub-install again as directed and it ran without error:

Code: Select all



(MX_21_Wildflower_) Sat Oct 15 06:11:50 /
chroot> sudo grub-install --target=i386-pc --recheck /dev/sdb
Installing for i386-pc platform.
Installation finished. No error reported.

(MX_21_Wildflower_) Sat Oct 15 06:12:23 /
chroot> update-grub
Generating grub configuration file ...
Warning: os-prober will be executed to detect other bootable partitions.
Its output will be used to detect bootable binaries on them and create new boot entries.
done

(MX_21_Wildflower_) Sat Oct 15 06:13:08 /

However, the system STILL boots to the grub> prompt. As directed I then did :

Code: Select all

grub-install --target=i386-pc  --recheck --modules=normal /dev/sda
This also ran without error, but the system STILL boots to grub> prompt.

I'm at a loss here.

Thanks for any additional help.

Huckleberry Finn

Re: GRUB broken on newly updated MX-21

#8 Post by Huckleberry Finn »

Enter Bios settings, change boot mode to Uefi (or at least have a check...) save & exit.

Chroot the same way, this time:

Code: Select all

grub-install --force-extra-removable --target=x86_64-efi --efi-directory=/boot/efi --bootloader-id=MX21 --recheck
Open GParted and right click on sda5 (in fact, that's too big, no harm but just waste of space: 7.5 GiB .. You can create a smaller one if you like, say 100-250 MiB and use that one) and put both boot and esp flags there.
____________________________

... Or (don't do the above), just open GParted and create a very tiny (say, 2 MiB) partition, (purposely) leave it unformatted, then right click on it: "Manage Flags": flag as bios_grub

User avatar
fehlix
Developer
Posts: 12932
Joined: Wed Apr 11, 2018 5:09 pm

Re: GRUB broken on newly updated MX-21

#9 Post by fehlix »

OK, Huck recommend to switch to UEFI, probably a valid consideration.

Now, comming back to your last post.
I'm missing information about what is actually your boot drive,
which normally you would set within the BIOS settings of the motherboard
or select at boot up.

To figure this out:
within chroot list the drives and post here:

Code: Select all

lsblk -f
b/c as already mentioned the drive name sda or sdb can be differently
assigned at every boot depending whether some other drive like USB are plugged in.
Now,the error mesages indicate a wrong debconf entry:
pls post with chroot:

Code: Select all

debconf-show grub-pc
and this in chroot

Code: Select all

cat /etc/fstab
and this

Code: Select all

find /boot/grub /grub -name 'grub*' -ls
Thanks

theprofa325
Posts: 21
Joined: Sat Jan 11, 2020 9:13 am

Re: GRUB broken on newly updated MX-21

#10 Post by theprofa325 »

OK, here we go.

Code: Select all

(MX_21_Wildflower_) Tue Oct 18 12:00:46 /
chroot> lsblk -f
NAME   FSTYPE   FSVER LABEL       UUID                                 FSAVAIL FSUSE% MOUNTPOINT
loop0  squashfs 4.0                                                                   
sda                                                                                   
├─sda1 ext4     1.0   boot        d7cfca98-066b-412d-9ce1-61ac30fecdd9  841.3M     2% /boot
├─sda2                                                                                
├─sda3 swap     1                 00c1711d-adb1-4c4f-b016-a816c5f28e41                [SWAP]
├─sda5 vfat     FAT32 EFI System  384C-8803                                           
├─sda6 ext4     1.0               f34eb12a-6be7-4efa-9659-30ddbed586a3                
└─sda7 ext4     1.0   rootMX21    9c79d178-2a9e-4556-b52a-8236447d0732   29.2G    45% /
sdb                                                                                   
└─sdb1 ext2     1.0               217152e1-762e-4c18-9ced-8fccf1aef54c                
sdh                                                                                   
├─sdh1 ext4     1.0   MX-Live-usb c47699b7-771f-4826-a227-90b6de737c16                
└─sdh2 vfat     FAT32 MX-UEFI     516E-0C48                                           
sr0                

and the debconf-show:

Code: Select all

chroot> debconf-show grub-pc
  grub-pc/postrm_purge_boot_grub: false
  grub-pc/partition_description:
  grub-pc/mixed_legacy_and_grub2: true
  grub2/kfreebsd_cmdline_default: quiet
  grub-pc/install_devices_failed: false
  grub-pc/hidden_timeout: false
  grub2/update_nvram: true
  grub-pc/disk_description:
  grub-pc/chainload_from_menu.lst: true
  grub2/kfreebsd_cmdline:
  grub-pc/install_devices_failed_upgrade: true
  grub-pc/kopt_extracted: false
  grub-pc/timeout: 5
  grub2/force_efi_extra_removable: false
  grub2/linux_cmdline_default: quiet splash
  grub-pc/install_devices_empty: false
* grub-pc/install_devices: /dev/disk/by-id/ata-CT1000MX500SSD1_2043E4BD4AA0-part1
  grub2/linux_cmdline:
  grub-pc/install_devices_disks_changed:

(MX_21_Wildflower_) Tue Oct 18 12:04:40 /

And the fstab listing:

Code: Select all


chroot> cat /etc/fstab
# Pluggable devices are handled by uDev, they are not in fstab
UUID=9c79d178-2a9e-4556-b52a-8236447d0732 / ext4 noatime 1 1
UUID=d7cfca98-066b-412d-9ce1-61ac30fecdd9 /boot ext4 noatime 1 1
UUID=f34eb12a-6be7-4efa-9659-30ddbed586a3 /home ext4 noatime 1 2
/dev/sda3	nont	swap	sw	0	0

(MX_21_Wildflower_) Tue Oct 18 12:06:13 /

And finally the find command (taught me some new "find" functionality here!)

Code: Select all

chroot> find /boot/grub /grub -name 'grub*' -ls
     7633      4 drwxr-xr-x   6 root     root         4096 Oct 15 06:13 /boot/grub
      334    132 -rw-r--r--   1 root     root       135168 Sep 30 11:30 /boot/grub/x86_64-efi/grub.efi
      332      4 -rw-r--r--   1 root     root         1024 Sep 30 11:30 /boot/grub/grubenv
      337      4 -rw-r--r--   1 root     root         3142 Oct 15 06:13 /boot/grub/grub.cfg
find: ‘/grub’: No such file or directory
Note that I have executed the grub repair tool multiple times with various options so there could be redundancy here.

Thanks for all the dedicated help. I'm living off my (obsessively backed up) laptop but my day job doesn't stop so I can only work on this every other day or so.

Post Reply

Return to “Bugs and Non-Package Requests Forum”