Booting to GRUB and mounting errors

Questions about Grub, UEFI,the liveCD and the installer
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Kevito
Level 1
Level 1
Posts: 19
Joined: Mon Jun 13, 2022 12:32 pm

Booting to GRUB and mounting errors

Post by Kevito »

Hey I got 10.3. I shut down properly other day and later turned on again went to grub screen. I tried all the fixes and nothing works just goes on boot to mounting errors file or dir not found drops to shell and initramfs prompt. Thing I notice is it's trying to load sys proc dev run from dir root and they are not in my root they are in the main dir of hd0,msdos drive sda1. They only thing showing in root is Desktop/. All my kernels are 5.4.0-74 to 119. Last time did updates right before shutdown Wi-Fi was dropping and maybe caused the problems. Also I can't get to grub boot menu with any key always goes to grub or bios. Plz help and thanx.
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
Kevito
Level 1
Level 1
Posts: 19
Joined: Mon Jun 13, 2022 12:32 pm

Re: Booting to GRUB and mounting errors

Post by Kevito »

Sorry it's Mint 20.3 not 10.3. Also I don't have a CD or USB stick computer came mint already installed and I upgraded online. I've ordered a live USB hoping to fix or at least copy files and reinstall. But am asking help to fix using grub or in initramfs meanwhile. Thanx.
deepakdeshp
Level 20
Level 20
Posts: 12341
Joined: Sun Aug 09, 2015 10:00 am

Re: Booting to GRUB and mounting errors

Post by deepakdeshp »

If I have helped you solve a problem, please add [SOLVED] to your first post title, it helps other users looking for help.
Regards,
Deepak

Mint 21.1 Cinnamon 64 bit with AMD A6 / 8GB
Mint 21.1 Cinnamon AMD Ryzen3500U/8gb
Kevito
Level 1
Level 1
Posts: 19
Joined: Mon Jun 13, 2022 12:32 pm

Re: Booting to GRUB and mounting errors

Post by Kevito »

Not sure where to do that fsck /dev/sda1 in initramfs does nothing. When it self runs keep getting

mount: mounting /dev on /root/dev failed: No such file or dir.
Same for run on /root/run.
Run_init can't exec.: No such....
Target filesystem doesn't have requested /sbin/init
etc.

What I can't understand is why it's trying to do in the root dir as all these dev sbin etc bin are main directories beside root on my sda1 and not subdirectories or root. They have the unit and sh files acc to ls commands. Maybe is there a way to change the mounting locations?
deepakdeshp
Level 20
Level 20
Posts: 12341
Joined: Sun Aug 09, 2015 10:00 am

Re: Booting to GRUB and mounting errors

Post by deepakdeshp »

In advance mode whats output of

Code: Select all

 sudo fdisk -l
If I have helped you solve a problem, please add [SOLVED] to your first post title, it helps other users looking for help.
Regards,
Deepak

Mint 21.1 Cinnamon 64 bit with AMD A6 / 8GB
Mint 21.1 Cinnamon AMD Ryzen3500U/8gb
pbear
Level 16
Level 16
Posts: 6569
Joined: Wed Jun 21, 2017 12:25 pm
Location: San Francisco

Re: Booting to GRUB and mounting errors

Post by pbear »

Try typing exit at the initramfs prompt, then fsck -fy /dev/sda1.

Note: No sudo is intentional, as it's not needed when running the command this way.
Kevito
Level 1
Level 1
Posts: 19
Joined: Mon Jun 13, 2022 12:32 pm

Re: Booting to GRUB and mounting errors

Post by Kevito »

On exit

Mount: mounting sus on /root/sus failed:No such....
... Proc on /root/proc fail....
/unit line 373:can't open /root/dev/console: No such....

Then goes into kernal panic and freezes, can't enter anything

????
deepakdeshp
Level 20
Level 20
Posts: 12341
Joined: Sun Aug 09, 2015 10:00 am

Re: Booting to GRUB and mounting errors

Post by deepakdeshp »

To run fsck from a live distribution like live USB.

Boot the live distribution.

Use fdisk or parted to find the root partition name.

Open the terminal and run:

sudo fsck -p /dev/sda1.
sda1 is your root partition

Once done, reboot the live distribution and boot your system.
If I have helped you solve a problem, please add [SOLVED] to your first post title, it helps other users looking for help.
Regards,
Deepak

Mint 21.1 Cinnamon 64 bit with AMD A6 / 8GB
Mint 21.1 Cinnamon AMD Ryzen3500U/8gb
pbear
Level 16
Level 16
Posts: 6569
Joined: Wed Jun 21, 2017 12:25 pm
Location: San Francisco

Re: Booting to GRUB and mounting errors

Post by pbear »

deepakdeshp wrote: Tue Jun 14, 2022 10:26 am Boot the live distribution.
Kevito wrote: Mon Jun 13, 2022 2:45 pm ... I don't have a CD or USB stick computer came mint already installed and I upgraded online.
So, yeah, you might have to wait until you get the live USB to fix this.
Kevito
Level 1
Level 1
Posts: 19
Joined: Mon Jun 13, 2022 12:32 pm

Re: Booting to GRUB and mounting errors

Post by Kevito »

Ok thanx then to both. Right I can't get to a terminal or grub boot menu to run sudo. I ordered both a live and a gparted sticks so will just wait till recieve and try that before I post any more.
deepakdeshp
Level 20
Level 20
Posts: 12341
Joined: Sun Aug 09, 2015 10:00 am

Re: Booting to GRUB and mounting errors

Post by deepakdeshp »

If I have helped you solve a problem, please add [SOLVED] to your first post title, it helps other users looking for help.
Regards,
Deepak

Mint 21.1 Cinnamon 64 bit with AMD A6 / 8GB
Mint 21.1 Cinnamon AMD Ryzen3500U/8gb
User avatar
AndyMH
Level 21
Level 21
Posts: 13743
Joined: Fri Mar 04, 2016 5:23 pm
Location: Wiltshire

Re: Booting to GRUB and mounting errors

Post by AndyMH »

Kevito wrote: Tue Jun 14, 2022 2:13 pm I ordered both a live and a gparted sticks so will just wait till recieve and try that before I post any more.
Don't need a gparted stick, there is a copy of gparted in the mint iso/stick.
Thinkcentre M720Q - LM21.3 cinnamon, 4 x T430 - LM21.3 cinnamon, Homebrew desktop i5-8400+GTX1080 Cinnamon 19.0
Kevito
Level 1
Level 1
Posts: 19
Joined: Mon Jun 13, 2022 12:32 pm

Re: Booting to GRUB and mounting errors

Post by Kevito »

Hey, from live terminal

root@mint:~# sudo fdisk -l
Disk /dev/loop0: 1.101 GiB, 2128023552 bytes, 4156296 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


Disk /dev/sda: 233.84 GiB, 251059544064 bytes, 490350672 sectors
Disk model: WDC WD2502ABYS-0
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: dos
Disk identifier: 0x059cb471

Device Boot Start End Sectors Size Id Type
/dev/sda1 * 2048 1050623 1048576 512M b W95 FAT32
/dev/sda2 1052670 490348543 489295874 233.3G 5 Extended
/dev/sda5 1052672 490348543 489295872 233.3G 83 Linux


Disk /dev/sdb: 2.75 TiB, 3000592982016 bytes, 5860533168 sectors
Disk model: HGST HUS724030AL
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes


Disk /dev/sdc: 14.66 GiB, 15728640000 bytes, 30720000 sectors
Disk model: ProductCode
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: dos
Disk identifier: 0x2d7faf9b

Device Boot Start End Sectors Size Id Type
/dev/sdc1 * 0 4397759 4397760 2.1G 0 Empty
/dev/sdc2 640 8639 8000 3.9M ef EFI (FAT-12/16/32)
/dev/sdc3 4399104 30719999 26320896 12.6G 83 Linux


Disk /dev/sdd: 931.49 GiB, 1000170586112 bytes, 1953458176 sectors
Disk model: My Passport 0827
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: dos
Disk identifier: 0xf588007a

Device Boot Start End Sectors Size Id Type
/dev/sdd1 2048 1953458175 1953456128 931.5G 7 HPFS/NTFS/exFAT


root@mint:~# fsck -fy /dev/sda1.
fsck from util-linux 2.34
e2fsck 1.45.5 (07-Jan-2020)
fsck.ext2: No such file or directory while trying to open /dev/sda1.
Possibly non-existent device?
root@mint:~#
root@mint:~#
root@mint:~# sudo fsck -p /dev/sda1
fsck from util-linux 2.34
fsck.fat 4.1 (2017-01-24)
/dev/sda1: 0 files, 1/130812 clusters


root@mint:~# fsck -fy /dev/sda1
fsck from util-linux 2.34
fsck.fat 4.1 (2017-01-24)
/dev/sda1: 0 files, 1/130812 clusters
root@mint:~# sudo fsck -fy /dev/sda1
fsck from util-linux 2.34
fsck.fat 4.1 (2017-01-24)
/dev/sda1: 0 files, 1/130812 clusters


I'm able to access and view all the files so must be software problem. I checked around web and others have this problem after recent update. I believe what happened was I started the updates my connexion dropped so they didn't finish. Later I shut down system which must have corrupted something so it now won boot. So unless anyone has some other suggestion I guess I will have to do an install over.

Thanx.
pbear
Level 16
Level 16
Posts: 6569
Joined: Wed Jun 21, 2017 12:25 pm
Location: San Francisco

Re: Booting to GRUB and mounting errors

Post by pbear »

If you're new to Linux, I recommend you get out of the habit of switching to the user root. Instead, run commands with sudo, which is how the system is designed to work. Also, no, the download failure didn't cause this - if the download is incomplete the files just sit in cache.

Anyhoo, try sudo fsck -fy /dev/sda5. This is why deepak suggested you run fdisk; it says sda5 is your system partition.

If that doesn't solve the problem, please post your system information.
Kevito
Level 1
Level 1
Posts: 19
Joined: Mon Jun 13, 2022 12:32 pm

Re: Booting to GRUB and mounting errors

Post by Kevito »

Ok ran that looks like it may have done something

mint@mint:~$ sudo fsck -fy /dev/sda5
fsck from util-linux 2.34
e2fsck 1.45.5 (07-Jan-2020)
Pass 1: Checking inodes, blocks, and sizes
Pass 2: Checking directory structure
Pass 3: Checking directory connectivity
Pass 4: Checking reference counts
Pass 5: Checking group summary information
/dev/sda5: 1522240/15294464 files (1.0% non-contiguous), 19664415/61161984 blocks
mint@mint:~$


so yeah will try reboot and see.

Thanx.
Kevito
Level 1
Level 1
Posts: 19
Joined: Mon Jun 13, 2022 12:32 pm

Re: Booting to GRUB and mounting errors

Post by Kevito »

Ok still boots to GRUB so here is system report

Code: Select all

System:    Kernel: 5.4.0-91-generic x86_64 bits: 64 compiler: gcc v: 9.3.0 Desktop: Cinnamon 5.2.7 
           wm: muffin dm: LightDM Distro: Linux Mint 20.3 Una base: Ubuntu 20.04 focal 
Machine:   Type: Desktop System: Gigabyte product: N/A v: N/A serial: <filter> Chassis: type: 3 
           serial: <filter> 
           Mobo: Gigabyte model: F2A68HM-H v: x.x serial: <filter> UEFI: American Megatrends v: FC 
           date: 01/19/2016 
CPU:       Topology: Quad Core model: AMD A8 PRO-7600B R7 10 Compute Cores 4C+6G bits: 64 
           type: MCP arch: Steamroller rev: 1 L2 cache: 2048 KiB 
           flags: avx lm nx pae sse sse2 sse3 sse4_1 sse4_2 sse4a ssse3 svm bogomips: 24754 
           Speed: 3094 MHz min/max: 1400/3100 MHz Core speeds (MHz): 1: 3094 2: 3094 3: 1493 
           4: 1565 
Graphics:  Device-1: AMD Kaveri [Radeon R7 Graphics] vendor: Gigabyte driver: radeon v: kernel 
           bus ID: 00:01.0 chip ID: 1002:1313 
           Display: x11 server: X.Org 1.20.11 driver: ati,radeon unloaded: fbdev,modesetting,vesa 
           resolution: 1366x768~60Hz 
           OpenGL: renderer: AMD KAVERI (DRM 2.50.0 5.4.0-91-generic LLVM 12.0.0) 
           v: 4.5 Mesa 21.0.3 direct render: Yes 
Audio:     Device-1: AMD Kaveri HDMI/DP Audio vendor: Gigabyte driver: snd_hda_intel v: kernel 
           bus ID: 00:01.1 chip ID: 1002:1308 
           Device-2: AMD FCH Azalia vendor: Gigabyte driver: snd_hda_intel v: kernel 
           bus ID: 00:14.2 chip ID: 1022:780d 
           Sound Server: ALSA v: k5.4.0-91-generic 
Network:   Device-1: Realtek RTL8111/8168/8411 PCI Express Gigabit Ethernet vendor: Gigabyte 
           driver: r8169 v: kernel port: e000 bus ID: 01:00.0 chip ID: 10ec:8168 
           IF: enp1s0 state: down mac: <filter> 
           IF-ID-1: usb0 state: unknown speed: N/A duplex: N/A mac: <filter> 
Drives:    Local Storage: total: 3.88 TiB used: 703.74 GiB (17.7%) 
           ID-1: /dev/sda vendor: Western Digital model: WD2502ABYS-01B7A0 size: 233.82 GiB 
           speed: 3.0 Gb/s serial: <filter> temp: 35 C 
           ID-2: /dev/sdb vendor: HGST (Hitachi) model: HUS724030ALA640 size: 2.73 TiB 
           speed: 6.0 Gb/s serial: <filter> temp: 37 C 
           ID-3: /dev/sdc type: USB vendor: Western Digital model: WD My Passport 0827 
           size: 931.48 GiB serial: <filter> 
           ID-4: /dev/sdd type: USB model: N/A size: 14.65 GiB serial: <filter> 
Partition: ID-1: / size: 1.65 GiB used: 277.6 MiB (16.4%) fs: overlay source: ERR-102 
           ID-2: /var/log size: 12.29 GiB used: 46.3 MiB (0.4%) fs: ext4 dev: /dev/sdd3 
USB:       Hub: 1-0:1 info: Full speed (or root) Hub ports: 5 rev: 2.0 chip ID: 1d6b:0002 
           Device-1: 1-3:64 info: LG G2 Android Phone [tethering mode] 
           type: Bluetooth,CDC-Data,Abstract (modem) driver: cdc_acm,rndis_host rev: 2.0 
           chip ID: 1004:6344 
           Device-2: 1-4:3 info: USB Disk 2.0 type: Mass Storage driver: usb-storage rev: 2.0 
           chip ID: 346d:5678 
           Hub: 2-0:1 info: Full speed (or root) Hub ports: 5 rev: 2.0 chip ID: 1d6b:0002 
           Hub: 3-0:1 info: Full speed (or root) Hub ports: 5 rev: 1.1 chip ID: 1d6b:0001 
           Hub: 4-0:1 info: Full speed (or root) Hub ports: 5 rev: 1.1 chip ID: 1d6b:0001 
           Device-3: 4-2:2 info: Logitech Media Keyboard K200 type: Keyboard,HID 
           driver: hid-generic,usbhid rev: 1.1 chip ID: 046d:c31d 
           Device-4: 4-3:3 info: Primax Dell N889 Optical Mouse type: Mouse 
           driver: hid-generic,usbhid rev: 2.0 chip ID: 0461:4d81 
           Hub: 5-0:1 info: Full speed (or root) Hub ports: 2 rev: 1.1 chip ID: 1d6b:0001 
           Hub: 6-0:1 info: Full speed (or root) Hub ports: 2 rev: 2.0 chip ID: 1d6b:0002 
           Hub: 7-0:1 info: Full speed (or root) Hub ports: 2 rev: 3.0 chip ID: 1d6b:0003 
           Device-5: 7-2:2 info: Western Digital My Passport 0827 type: Mass Storage 
           driver: usb-storage rev: 3.0 chip ID: 1058:0827 
Sensors:   System Temperatures: cpu: 19.0 C mobo: N/A gpu: radeon temp: 17 C 
           Fan Speeds (RPM): N/A 
Repos:     Active apt repos in: /etc/apt/sources.list 
           1: deb cdrom:[Linux Mint 20.3 _Una_ - Release amd64 20220104]/ focal contrib main
           Active apt repos in: /etc/apt/sources.list.d/official-package-repositories.list 
           1: deb http: //packages.linuxmint.com una main upstream import backport #id:linuxmint_main
           2: deb http: //archive.ubuntu.com/ubuntu focal main restricted universe multiverse
           3: deb http: //archive.ubuntu.com/ubuntu focal-updates main restricted universe multiverse
           4: deb http: //archive.ubuntu.com/ubuntu focal-backports main restricted universe multiverse
           5: deb http: //security.ubuntu.com/ubuntu/ focal-security main restricted universe multiverse
           6: deb http: //archive.canonical.com/ubuntu/ focal partner
Info:      Processes: 213 Uptime: 13h 39m Memory: 3.30 GiB used: 2.59 GiB (78.4%) Init: systemd 
           v: 245 runlevel: 5 Compilers: gcc: 9.3.0 alt: 9 Client: Unknown python3.8 client 
           inxi: 3.0.38 
If this can-t be resolved its not a big deal if I have to reinstall Linux since all my data is backed up and all my istalled programs were just free downloaded.

Thanx.
User avatar
AndyMH
Level 21
Level 21
Posts: 13743
Joined: Fri Mar 04, 2016 5:23 pm
Location: Wiltshire

Re: Booting to GRUB and mounting errors

Post by AndyMH »

You can re-install grub, looks like you have linux on sda installed in legacy mode (drive with a legacy partition table - you can tell, you have an extended partition):

Code: Select all

Device Boot Start End Sectors Size Id Type
/dev/sda1 * 2048 1050623 1048576 512M b W95 FAT32
/dev/sda2 1052670 490348543 489295874 233.3G 5 Extended
/dev/sda5 1052672 490348543 489295872 233.3G 83 Linux
Boot your mint install stick, open a terminal and confirm you are booting in legacy mode with efibootmgr:

Code: Select all

andy@T432 ~ $ efibootmgr
EFI variables are not supported on this system.
if you get this it's booting legacy, anything else is UEFI boot.

Assuming legacy boot then:

Code: Select all

sudo mount /dev/sda5 /mnt 
sudo grub-install --boot-directory=/mnt/boot /dev/sda 
and reboot.
Thinkcentre M720Q - LM21.3 cinnamon, 4 x T430 - LM21.3 cinnamon, Homebrew desktop i5-8400+GTX1080 Cinnamon 19.0
pbear
Level 16
Level 16
Posts: 6569
Joined: Wed Jun 21, 2017 12:25 pm
Location: San Francisco

Re: Booting to GRUB and mounting errors

Post by pbear »

From the inxi report, I see you were booted in UEFI mode at that time. OTOH, Andy is right that you installed in BIOS mode (aka legacy mode). So, obviously you have an option to boot the USB drive either way. Be sure to use BIOS/legacy mode when booting to reinstall Grub.
Kevito
Level 1
Level 1
Posts: 19
Joined: Mon Jun 13, 2022 12:32 pm

Re: Booting to GRUB and mounting errors

Post by Kevito »

Hey I got this

mint@mint:~$ efibootmgr
BootCurrent: 0007
Timeout: 1 seconds
BootOrder: 0003,0007,0006,0002
Boot0002* Hard Drive
Boot0003* UEFI: WDC WD2502ABYS-01B7A0
Boot0006* WDC WD2502ABYS-01B7A0
Boot0007* UEFI: VendorCoProductCode 2.00
mint@mint:~$

Will this mean then I have the UEFI?

From

int@mint:~$ sudo fdisk -l
Disk /dev/loop0: 1.101 GiB, 2128023552 bytes, 4156296 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


Disk /dev/sda: 233.84 GiB, 251059544064 bytes, 490350672 sectors
Disk model: WDC WD2502ABYS-0
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: dos
Disk identifier: 0x059cb471

Device Boot Start End Sectors Size Id Type
/dev/sda1 * 2048 1050623 1048576 512M b W95 FAT32
/dev/sda2 1052670 490348543 489295874 233.3G 5 Extended
/dev/sda5 1052672 490348543 489295872 233.3G 83 Linux

will this be

system partition = sda5
EFI partition = sda1?

Thanks for help I'm still learning this.
User avatar
AndyMH
Level 21
Level 21
Posts: 13743
Joined: Fri Mar 04, 2016 5:23 pm
Location: Wiltshire

Re: Booting to GRUB and mounting errors

Post by AndyMH »

Yes and not what I expected*!

Simple test - go into BIOS have a look at your boot settings, if set UEFI (what I expect) change to legacy and try rebooting. Does it boot? You may have to either move HD0 to the top of your BIOS boot list or press the relevant function key at the manufacturers splash screen to get your one-time boot list and boot from HD0. Function key varies by manufacturer, on my thinkpads it is F12.

If that fails, boot your mint install stick, open the file manager. In the left hand pane under devices you should see your / partition on your main drive. It will be something like xxGB volume. Click on it, do you see the normal folders in / and are the files there:
Screenshot from 2022-06-20 16-39-30.png
this is a second copy of mint installed on another drive in my laptop. Want to check that the files are there, so that the problem is with boot and not something else.



* it used to be straightforward, a standard 'erase and install' legacy boot would only have a single partition for /. Changed with LM20 and legacy install, the installer creates a useless EFI partiton and puts your / partition inside an extended partition - which is what you have. Some call it a feature, I call it a bug. But you can have that setup and boot UEFI if you went out of your way to do it like that (unlikely?).
Thinkcentre M720Q - LM21.3 cinnamon, 4 x T430 - LM21.3 cinnamon, Homebrew desktop i5-8400+GTX1080 Cinnamon 19.0
Locked

Return to “Installation & Boot”