PDA

View Full Version : Grub minimal bash-like command after update?



bANONYMOUS
2018-07-31, 17:04
I updated kali 2018.2 using

# apt clean
# apt update
# apt upgrade
# apt dist-upgrade
# reboot

Now it boots to a black screen saying grub 2 minimal bash-like command

I can just type exit and it will either boot into grub and load normally, or I have to type exit, wait for it to reload the grub minimal bash-like command screen and type exit again and it loads normally.
So with this being said I can still fully boot into kali without issue, I just want to get rid of this screen, any suggestions?

I don't dual boot, everything I've found on this topic is about a windows install breaking grub, I only run Kali 2018.2 on this laptop

I've tried as follows from this (https://networkwolves.wordpress.com/2015/04/13/repair-kali-linux-grub-after-installing-window-in-dual-boot/) link
mount /dev/sda3 /mnt

But I get
mount: /mnt: unknown filesystem type 'swap'.

So I tried
mount /dev/sda /mnt

And it mounts normally without issue
I continue with the commands as follows

mount ?bind /dev /mnt/dev
mount ?bind /dev/pts /mnt/dev/pts
mount ?bind /proc /mnt/proc
mount ?bind /sys /mnt/sys
chroot /mnt
grub-install /dev/sda

And this is where I get
"Installing for x86_64-efi platform."
"grub-install: error: cannot find EFI directory"

And now I'm kind of at a loss and everything I've been looking up is telling me this has something to do with a Windows install but I don't even have windows on this, not really sure what's going on here.
Any suggestions?

bANONYMOUS
2018-07-31, 20:52
I made zero progress at getting this working, however I made it further than I was before, but still the same result.
I ran fdisk to find what partitions were what and noticed that sda1 is efi and sda2 is the filesystem, so I ran this series of commands and everything checks out fine, it just doesn't work, still boots into the grub recovery

So this is where I start
(sda1 is efi, sda2 is filesystem)

# mount /dev/sda2 /mnt
# mount /dev/sda1 /mnt/boot/efi
# mount --bind /dev /mnt/dev
# mount --bind /dev/pts /mnt/dev/pts
# mount --bind /proc /mnt/proc
# mount --bind /sys /mnt/sys
# chroot /mnt
# grub-install

At this point I get this read out, but it says nothing was wrong

"Installing for x86_64-efi platform
.libkmod: ERROR ../libkmod/libkmod-config.c:656 kmod_config_parse: /etc/modprobe.d/blacklist-nouvear.conf line 3: ignoring bad line starting with 'allias'
Installation finished. No error reported."

So I tried this command

# grub-install --target=x86_64-efi /dev/sda

And I'm given with the identical read out, I just ignored it since it says no error reported and installation finished, so I continued on with as follows

# update-grub
# exit
# umount /mnt/dev/pts
# umount /mnt/dev
# umount /mnt/proc
# umount /mnt/sys
# umount /dev/boot/efi
# umount /mnt
# reboot

But every time, I still reboot back into the grub recovery.

I also tried going through grub recovery by using these commands

# ls
# set root=(hd0,gpt2)
# set prefix=)hd0,gpt2)/boot/grub
# insmod normal
#normal

At this point, Kali boots normally and I can sign in, from Terminal I used these commands

#update-grub
#grub-install
#reboot

and again the same result, boots back into grub recovery

I've been trying to avoid using a Ubuntu Live USB and trying boot-repair because I want to try and figure this out myself, I just don't know where to go from here.

bANONYMOUS
2018-08-01, 19:03
Okay, fixed it, it had nothing to do with GRUB, I guess when I updated, it decided to make a new UEFI submission? And I guess the BIOS defaulted to it, I just changed the boot priority back to UEFI:kali in BIOS and now it boots totally fine, it's actually even faster than it was before and now for some reason it's also displaying the GRUB wallpaper at 1080p and looks a lot nicer as well haha.

Hopefully if anyone else is having a similar issue they find this and try the stuff I did to getting it all sorted out.