You are not logged in.

#1 2022-08-30 23:56:15

ExpHP
Member
Registered: 2017-04-08
Posts: 4

[SOLVED] Can't run install-grub due to kernel update: vfat not found

archlinux.org says to do grub-install after updating grub.  Sure.  I haven't updated my grub-install in a while so I should probably do that:

$ sudo grub-install
Installing for x86_64-efi platform.
grub-install: error: cannot find EFI directory.
$ ls /boot/efi
$ mount | grep /boot/efi
$

Hm.  Okay.  /boot/efi is not mounted.  Let's try and fix that:

$ sudo parted /dev/sdb print
Model: ATA SAMSUNG MZMTE512 (scsi)
Disk /dev/sdb: 512GB
Sector size (logical/physical): 512B/512B
Partition Table: gpt
Disk Flags: 

Number  Start   End    Size    File system     Name                          Flags
 1      1049kB  106MB  105MB   fat32           EFI system partition          boot, esp
 2      106MB   240MB  134MB                   Microsoft reserved partition  msftres
 3      240MB   249GB  249GB   ntfs            Basic data partition          msftdata
 6      249GB   258GB  8590MB  linux-swap(v1)                                swap
 7      258GB   260GB  2147MB  ext2            arch-boot
 5      260GB   497GB  237GB   ext4            arch
 4      497GB   512GB  14.7GB  ntfs            Basic data partition          msftdata

$ sudo mount /dev/sdb1 /boot/efi
mount: /boot/efi: unknown filesystem type 'vfat'.
       dmesg(1) may have more information after failed mount system call.

Hmm.  Reading around, it appears that fat32 support requires the vfat kernel module.  Okay....

$ modinfo vfat
modinfo: ERROR: Module vfat not found.
$ modprobe vfat
modprobe: FATAL: Module vfat not found in directory /lib/modules/5.15.61-1-lts
$ ls /lib/modules/5.15.61-1-lts
"/lib/modules/5.15.61-1-lts": No such file or directory (os error 2)
$ ls /lib/modules
5.15.63-1-lts  5.19.5-arch1-1
$

If I'm understanding correctly, it seems to me that I can't load the module because pacman also updated the kernel from 5.15.61-1-lts to 5.15.63-1-lts, and deleted the modules for the old version, which is the one that I'm currently booted into.

I'm now in a catch-22.  I shouldn't reboot my system until I ensure that my grub install is up to date, I can't update grub without running the new kernel, and I don't know how to use the new kernel without rebooting.

Last edited by ExpHP (2022-08-31 00:19:42)

Offline

#2 2022-08-30 23:58:30

Scimmia
Fellow
Registered: 2012-09-01
Posts: 9,555

Re: [SOLVED] Can't run install-grub due to kernel update: vfat not found

downgrade the kernel package to whatever version you're currently running.

Last edited by Scimmia (2022-08-30 23:58:55)

Online

#3 2022-08-31 00:09:18

ExpHP
Member
Registered: 2017-04-08
Posts: 4

Re: [SOLVED] Can't run install-grub due to kernel update: vfat not found

Okay, thanks.  I found the old package still present in /var/cache/pacman/pkg and did the following

$ sudo pacman --upgrade /var/cache/pacman/pkg/linux-lts-5.15.61-1-x86_64.pkg.tar.zst
loading packages...
warning: downgrading package linux-lts (5.15.63-1 => 5.15.61-1)
resolving dependencies...
looking for conflicting packages...

Packages (1) linux-lts-5.15.61-1

Total Installed Size:  131.00 MiB
Net Upgrade Size:        0.03 MiB

(...snip...)

Then I was able to mount the drive and update grub:

$ sudo mount /dev/sdb1 /boot/efi
$ sudo grub-install
Installing for x86_64-efi platform.
Installation finished. No error reported.
$ sudo grub-mkconfig -o /boot/grub/grub.cfg
Generating grub configuration file ...
Found linux image: /boot/vmlinuz-linux-lts
Found initrd image: /boot/initramfs-linux-lts.img
Found fallback initrd image(s) in /boot:  initramfs-linux-lts-fallback.img
Found linux image: /boot/vmlinuz-linux
Found initrd image: /boot/initramfs-linux.img
Found fallback initrd image(s) in /boot:  initramfs-linux-fallback.img
Warning: os-prober will not be executed to detect other bootable partitions.
Systems on them will not be added to the GRUB boot configuration.
Check GRUB_DISABLE_OS_PROBER documentation entry.
Adding boot menu entry for UEFI Firmware Settings ...
done

and reinstall the new kernel package

$ sudo pacman --upgrade /var/cache/pacman/pkg/linux-lts-5.15.63-1-x86_64.pkg.tar.zst

Hopefully everything is set now!

Edit: Yep, I was safely able to reboot.

Last edited by ExpHP (2022-08-31 00:20:44)

Offline

#4 2022-09-05 05:10:35

polo070770
Member
Registered: 2022-09-05
Posts: 1

Re: [SOLVED] Can't run install-grub due to kernel update: vfat not found

Newbie here! Thank you for sharing what you did @ExpHP, it worked for me!

Offline

Board footer

Powered by FluxBB