T
T
tj572017-09-26 22:54:56
linux
tj57, 2017-09-26 22:54:56

How to restore grub after installing ubuntu on disk and flash drive?

The situation is this:
Windows 8.1 was on the laptop, I decided to put ubuntu on a flash drive (since there is a large empty flash drive, and it’s not very advisable to put it next to Windows because of the small hdd of 120 GB). Since I didn’t immediately figure out how to put it on a flash drive, I decided to put it next to Windows for a start, in the end I installed it and everything worked well. Then I decided to put it on a flash drive, after the installation was completed, problems began:
1) Somehow GRUB and MBR were demolished from the disk. When you start from the disk, the following window opens: Yhd3RLB3oB8.jpg
2) When booting from a USB flash drive, GRUB opens, but it only allows you to enter the ubuntu that is on it. You can also go to Windows.
After I tried to restore grub according to the well-known guide
https://goo.gl/xig3Qr
Now the picture has become like this (when booting from disk):
IeqNAAX9Hto.jpg
But if at the same time a flash drive is inserted into the laptop (and the boot is loaded from the disk), then grub opens.
In general, how to restore grub on disk?

Answer the question

In order to leave comments, you need to log in

4 answer(s)
M
matsuhito, 2017-09-27
@matsuhito

generally a bad idea to put ubuntu on a flash drive. Even with 3.0, your axis will be unrealistically stupid.
If Windows plows go into it and reinstall the hornbeam through the partition wizard. The program is very convenient. There you will visually see what and whom you have overwritten.

M
Mikael Grigoryan, 2017-09-27
@temujin

Let's get more details, what file system, what partitions are on the disk?

R
Ruslan Jakushev, 2017-10-01
@lrusifikator

You can download some lightweight distribution like arch. You will mount the partitions on / mnt, then you will write arch-chroot / mnt. And install grub : grub-install /dev/sda && grub-mkconfig -o /boot/grub/grub.cfg and that's it

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question