error: cant't find command linux when booting system
The problem is the linux
and initrd
command used in /boot/efi/EFI/centos/grub.cfg
is not found in your centos (or any default boot OS).
You must replace the linux
to linuxefi
and initrd
to initrdefi
inside the grub.cfg file.So follow this operatins:
1 - boot to your centos terminal
2 - install grub2-efi
# yum install grub2-efi
4 - open the /boot/efi/EFI/centos/grub.cfg
using a text editor.
# vi /boot/efi/EFI/centos/grub.cfg
note: if grub.cfg did not exist try to /boot/grub2/grub.cfg
... if was not exist too, try to generate that: # grub2-mkconfig -o /boot/efi/EFI/centos/grub.cfg
5 - find all linux
command and replace to linuxefi. So, find all initrd command and replace to initrdefi
befor edit saples
linux /boot/vmlinuz-0-rescue-d1268bb1d6df49758a1ec5715984725c root=/dev/sda1
initrd /boot/initramfs-0-rescue-d1268bb1d6df49758a1ec5715984725c.img
after edit sample :
linuxefi /boot/vmlinuz-0-rescue-d1268bb1d6df49758a1ec5715984725c root=/dev/sda1
initrdefi /boot/initramfs-0-rescue-d1268bb1d6df49758a1ec5715984725c.img
6 - reboot
Related videos on Youtube
Admin
Updated on September 18, 2022Comments
-
Admin over 1 year
Recently I've installed CentOS 7 on my pc, previously I had debian 7 and manjaro installed. When I installed manjaro I overwrote the bootloader of debian and manjaro's grub recognized the two systems and all worked perfectly, now that I installed CentOS I overwrote /boot/efi and the new grub recognized the three systems but only CentOS works. When I try to boot debian or manjaro the following message appears:
error: cant't find command linux error: cant't find command initrd