You are not logged in.

#1 2023-05-20 08:47:29

taiongh
Member
Registered: 2018-10-04
Posts: 75

grub cannot be accessed after starting the computer

My computer is arch+win10 dual system, boot with grub.
Recently made an update, (usually I will update once a week). The same day after the update, and then restart the computer, the test is no problem.
The next day again boot, computer in the boot screen, keep restarting. Automatic restart after many times will automatically enter win10. Previously, the grub option appeared after the boot screen.
What do I need to do to save my computer?

Offline

#2 2023-05-20 10:51:51

seth
Member
Registered: 2012-09-03
Posts: 52,595

Re: grub cannot be accessed after starting the computer

Boot some live distro or the install iso and re-install grub (don't forget to mount the /boot partition and ESP - if any)

Online

#3 2023-05-20 12:56:39

taiongh
Member
Registered: 2018-10-04
Posts: 75

Re: grub cannot be accessed after starting the computer

Thank you. I'll try

Offline

#4 2023-05-22 15:35:50

taiongh
Member
Registered: 2018-10-04
Posts: 75

Re: grub cannot be accessed after starting the computer

seth wrote:

Boot some live distro or the install iso and re-install grub (don't forget to mount the /boot partition and ESP - if any)

I used a thumb drive to get back into the system.
First I checked my system using

 fdisk -l

.I confirmed that the system is EFI.

After that, I hooked up to the system

 
mount /dev/sda1 /mnt
mount /dev/sdb5 /mnt

(sda is the hard disk where I installed arch and sdb is the hard disk where win resides)

I use

arch-chroot /mnt

to get to root

Then I uninstalled gurb, along with its dependencies.

 pacman -Rcsn os-prober ntfs-3g grub efibootmgr

After uninstall I network

 dhcpcd

Then I perform an update to make sure the system is up to date before installing again

 pacman -Syu
pacman -S os-prober ntfs-3g
pacman -S grub
pacman -S efibootmgr

Then I deploy grub:

[root@archiso /]# grub-install --target=x86_64-efi --efi-directory=/boot --bootloader-id=grub
installing for x86_64-efi platform.
installation finished.  No error reported.

Up to this point, I didn't see a problem.

Then generate the configuration file:

root@archiso /]# grub-mkconfig -o /boot/grub/grub.cfg
Generating grub configuration file ...
Found linux image: /boot/vmlinuz-linx
Found initrd image: /boot/intel-ucode.img /boot/initramfs-linux.img
Found fallback initrd image(s) in /boot: inter-ucode.img initramfs-linux-fallback.img
/etc/grub.d/proxifiedScripts/linux: line 200: version_find_latest: command not found
Warning: os-prober will not be executedto detect other bootable partitions.
Systems on them will not be added to the GRUB boot configuration.
Check GRUB_DISABLE_OS_PEOBER documentation entry.
Adding boot menu entry for UEFI Firmware Settings ...
/etc/grub.d/proxifiedScripts/linux: line 200: version_find_latest: command not found
Adding boot menu entry for UEFI Firmware Settings ...
done
[root@archiso /]#

What seems to be the problem that is not identifying all the systems

I tried to check the gurb results

nano /boot/grub/grub.cfg

arch exists, but Windows does not.

Reboot into the BIOS, and in the Settings, the Windows and GRUB options are found. Sure enough, when I set GRUB as the first option, Windows is not included in GRUB when I boot it up.
Now what can I do to restore both arch and Windows in GRUB?

Last edited by taiongh (2023-05-22 15:37:47)

Offline

#5 2023-05-22 17:29:26

Head_on_a_Stick
Member
From: London
Registered: 2014-02-20
Posts: 7,771
Website

Re: grub cannot be accessed after starting the computer

taiongh wrote:
mount /dev/sda1 /mnt
mount /dev/sdb5 /mnt

That cannot be correct. I presume the second command actually used "/mnt/boot" as an argument?

taiongh wrote:

arch exists, but Windows does not.

taiongh also wrote:
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_PEOBER documentation entry.

It always helps to actually *read* the error message. See also https://wiki.archlinux.org/title/GRUB#D … ng_systems.

EDIT: on reflection, transferring information from eye to hand without any intervening brain activity is quite impressive, in it's own way. Well done! tongue

Last edited by Head_on_a_Stick (2023-05-22 17:45:46)

Offline

#6 2023-05-23 15:13:12

taiongh
Member
Registered: 2018-10-04
Posts: 75

Re: grub cannot be accessed after starting the computer

Head_on_a_Stick wrote:
taiongh wrote:
mount /dev/sda1 /mnt
mount /dev/sdb5 /mnt

That cannot be correct. I presume the second command actually used "/mnt/boot" as an argument?

taiongh wrote:

arch exists, but Windows does not.

taiongh also wrote:
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_PEOBER documentation entry.

It always helps to actually *read* the error message. See also https://wiki.archlinux.org/title/GRUB#D … ng_systems.

EDIT: on reflection, transferring information from eye to hand without any intervening brain activity is quite impressive, in it's own way. Well done! tongue


First of all thank you very much.
One error, and I did get it wrong, is /mnt/boot.


Then I followed your instructions, and according to the wiki, I found it

/etc/default/grub

And uncomment it

GRUB_DISABLE_OS_PROBER=false

Then came a new mistake:

root@archiso /]# grub-mkconfig -o /boot/grub/grub.cfg
Generating grub configuration file ...
Found linux image: /boot/vmlinuz-linx
Found initrd image: /boot/intel-ucode. img /boot/initramfs-linux.img
Found fallback initrd image(s) in /boot: inter-ucode. img initramfs-linux-fallback.img
/etc/grub. d/proxifiedScripts/linux: line 200: version_find_latest: command not found
Warning: os-prober will not be executedto detect other bootable partitions.
Its output will be used to detect bootable binaries on them and create new boot entries.
ERROR: mkdir /var/lock/dmraid
Grub-probe:error:cannot find a GRUB drive for /dev/sdc1.  Check your device.map.
Adding boot menu entry for UEFI Firmware Settings ...
/etc/grub. d/proxifiedScripts/linux: line 200: version_find_latest: command not found
Adding boot menu entry for UEFI Firmware Settings ...
done

[root@archiso /]#

I tried to find the answer, but without success.


In addition, there is a very strange situation:
After I installed gurb yesterday, it was at least bootable. But today gurb disappeared again and I had to reinstall it again.


I wonder if this is because I didn't uninstall clean grub when reinstalling?


My uninstall input is:

pacman -Rcsn os-prober ntfs-3g grub efibootmgr

Offline

#7 2023-05-23 19:42:43

seth
Member
Registered: 2012-09-03
Posts: 52,595

Re: grub cannot be accessed after starting the computer

taiongh wrote:

My uninstall input is:

pacman -Rcsn os-prober ntfs-3g grub efibootmgr

Do you understand what that does?
Do you understand why your windows partition isn't added to grub?

/etc/grub.d/proxifiedScripts/linux: line 200: version_find_latest: command not found

That error is from grub-customizer and is not relevant to the situation at hand.

Online

#8 2023-05-25 14:39:47

taiongh
Member
Registered: 2018-10-04
Posts: 75

Re: grub cannot be accessed after starting the computer

seth wrote:
taiongh wrote:

My uninstall input is:

pacman -Rcsn os-prober ntfs-3g grub efibootmgr

Do you understand what that does?
Do you understand why your windows partition isn't added to grub?

/etc/grub.d/proxifiedScripts/linux: line 200: version_find_latest: command not found

That error is from grub-customizer and is not relevant to the situation at hand.

Although I finally did not solve, but still thank you for your answer. Unfortunately, I switched systems.

Offline

Board footer

Powered by FluxBB