Page 1 of 3 123 LastLast
Results 1 to 10 of 25

Thread: boot-repair can't reinstall grub

  1. #1

    boot-repair can't reinstall grub

    My boot-repair url is http://paste.ubuntu.com/5638657/

    New machine (Gateway DX4380-UR308), came with Win 8. I tried to install 64-bit Ubuntu 12.04 Desktop (using an iso downloaded ~2 days ago). I booted from CD, selected install, had the entire disk wiped. Install seemed to go fine. I was able to install xfce and a few other things, configure the desktop, etc. But, when I rebooted, I got a boot error on startup. I followed the instructions at https://help.ubuntu.com/community/UEFI I was able to run boot-repair, but it hung while reinstalling grub. After waiting ~30 mins, I killed it and rebooted. I got to a grub prompt, but didn't know what to do at that point. I tried boot-repair again and had the same problem.

    I have disabled SecureBoot in my BIOS.

    Any help is appreciated!

    Jason
    Last edited by pussinboots; March 26th, 2013 at 03:57 AM. Reason: mark as solved

  2. #2

    Re: boot-repair can't reinstall grub

    I just tried installing 12.10 (64-bit Ubuntu Desktop) and ran into the same problem. The first reboot after install was successful. But, when I rebooted a 2nd time, I got the same message as before ("Reboot and Select proper Boot Device or Insert Boot Media in selected device and press a key") at startup. And, when I try to use boot-repair, it hangs while trying to "Reinstall GRUB. This may require several minutes..." "top" shows boot-repair.sh max-ing out a single core (99.9% cpu).

  3. #3
    Join Date
    Jan 2008
    Location
    France
    Beans
    Hidden!
    Distro
    Ubuntu Development Release

    Re: boot-repair can't reinstall grub

    hello,
    You are the 2nd one I see with this problem. Please open a terminal, maximize it, run:
    sudo boot-repair -d
    then click Recommended Repair, and look carefully in the terminal.
    What are the last lines before it hangs? (ignore the "pulse" lines)

  4. #4

    Re: boot-repair can't reinstall grub

    Here's the last 30 or so lines before it hung. It was all pulse's after the "Boot EFI files" line.

    => [[ PY ]] => [debug]/mnt/boot-sav/sda2/etc/fstab unchanged for /boot
    => [[ PY ]] => SET@_progressbar1.pulse()
    => [[ PY ]] => [debug]/mnt/boot-sav/sda2/etc/fstab unchanged for /usr
    => [[ PY ]] => [debug]/mnt/boot-sav/sda2/etc/fstab unchanged for /boot/efi
    => [[ PY ]] => [debug]Freed space function
    => [[ PY ]] => SET@_label0.set_text('''Checking full partitions. This may require several minutes...''')
    => [[ PY ]] => [debug]force_unmount_and_prepare_chroot
    => [[ PY ]] => [debug]Unmount all OS partitions except / and partition where we reinstall GRUB (sda2)
    => [[ PY ]] => SET@_label0.set_text('''Unmount all except sda2. This may require several minutes...''')
    => [[ PY ]] => [debug]prepare_chroot
    => [[ PY ]] => SET@_label0.set_text('''Applying changes. (chroot). This may require several minutes...''')
    => [[ PY ]] => [debug] Already mounted /dev/sda2 on /mnt/boot-sav/sda2
    => [[ PY ]] => [debug] mount_separate_boot_if_required yes , , grub-efi-amd64-signed ,
    => [[ PY ]] => SET@_progressbar1.pulse()
    => [[ PY ]] => Mount sda1 on /mnt/boot-sav/sda2/boot/efi
    => [[ PY ]] => Files in /mnt/boot-sav/sda2/boot/efi: /EFI/ubuntu/grub.cfg /EFI/ubuntu/grubx64.efi /EFI/ubuntu/shimx64.efi /EFI/ubuntu /EFI
    => [[ PY ]] => Boot EFI files in /mnt/boot-sav/sda2/boot/efi:
    => [[ PY ]] => SET@_label0.set_text('''Unhide boot menu. This may require several minutes...''')
    => [[ PY ]] => SET@_progressbar1.pulse()
    => [[ PY ]] => [debug]End fix /mnt/boot-sav/sda2/etc/grub.d/
    [...]
    => [[ PY ]] => grub-install (GRUB) 2.00-7ubuntu11,grub-install (GRUB) 2.
    => [[ PY ]] =>
    => [[ PY ]] => Reinstall the grub-efi-amd64-signed of sda2
    => [[ PY ]] => SET@_label0.set_text('''Reinstall GRUB . This may require several minutes...''')
    [...]
    => [[ PY ]] => Installation finished. No error reported.
    => [[ PY ]] => grub-install --efi-directory=/boot/efi --target=x86_64-efi --uefi-secure-boot : BootCurrent: 0003
    => [[ PY ]] => Timeout: 2 seconds
    => [[ PY ]] => BootOrder: 0003,0002,0001
    => [[ PY ]] => Boot0001 Windows Boot Manager
    => [[ PY ]] => Boot0002* UEFI: ST31000524AS
    => [[ PY ]] => Boot0003* UEFI: HL-DT-ST DVDRAM GH82N
    => [[ PY ]] => BootCurrent: 0003
    => [[ PY ]] => Timeout: 2 seconds
    => [[ PY ]] => BootOrder: 0000,0003,0002,0001
    => [[ PY ]] => Boot0001 Windows Boot Manager
    => [[ PY ]] => Boot0002* UEFI: ST31000524AS
    => [[ PY ]] => Boot0003* UEFI: HL-DT-ST DVDRAM GH82N
    => [[ PY ]] => Boot0000* ubuntu
    => [[ PY ]] => exit code of grub-install :0
    => [[ PY ]] => SET@_progressbar1.pulse()
    => [[ PY ]] => Files in /mnt/boot-sav/sda2/boot/efi: /EFI/ubuntu/grub.cfg /EFI/ubuntu/grubx64.efi /EFI/ubuntu/shimx64.efi /EFI/ubuntu /EFI
    => [[ PY ]] => Boot EFI files in /mnt/boot-sav/sda2/boot/efi:

  5. #5

    Re: boot-repair can't reinstall grub

    My first reboot after running boot-repair was successful---it went right into Ubuntu. But, then I rebooted again and got the BIOS error message ("Select proper Boot Device").

  6. #6

    Re: boot-repair can't reinstall grub

    One odd thing I've noticed is that sometimes the BIOS uses "UEFI: HL-DT-ST DVDRAM GH82N" to name the DVD drive (in boot priority options); other times it uses a much simpler name like "CD/DVD". I don't see any option to select whether drives use UEFI mode or not...

  7. #7
    Join Date
    Nov 2009
    Location
    Catalunya, Spain
    Beans
    14,558
    Distro
    Ubuntu 18.04 Bionic Beaver

    Re: boot-repair can't reinstall grub

    Yann can help you more with boot-repair since he developed the software. Also, I don't use UEFI but I have few things to point out:
    On new UEFI enabled computers/boards for most boot devices you have two separate devices, the older legacy boot version and the UEFI version (usually with UEFI prefix). That applies to optical drives, usb sticks, etc.

    If you don't want to use uefi boot, you should look for an option in bios and whether you can disable it. BUT if windows came preinstalled in uefi mode with your machine, you can't simply disable it, it will not boot windows any more. So, you have to stick with uefi boot.

    Having said that, uefi dual boot still has issues, and it doesn't help that manufacturers are thinking only about Microsoft when developing products. One VERY important thing, is that if win8 is in uefi mode you HAVE TO install ubuntu in uefi mode too. In other words, you have to boot the ubuntu cd/usb with the UEFI prefix when installing. If you booted the legacy optical drive, it would load the cd in legacy mode and installing ubuntu in legacy mode (installing legacy version of grub2 instead of the uefi version).

    With ubuntu you have options to "switch" grub2 to uefi version, but a new install might be easier.

    How did you install ubuntu, which device did you boot?
    Darko.
    -----------------------------------------------------------------------
    Ubuntu 18.04 LTS 64bit

  8. #8

    Re: boot-repair can't reinstall grub

    According to https://help.ubuntu.com/community/UEFI my CD/DVD is booting in UEFI mode because I see the boot menu screen with "Try Ubuntu..." "Install Ubuntu" "Check disc...". I have tried installing directly from CD/DVD (at boot menu, select "install") and first using the live version ("Try Ubuntu") then installing via the desktop icon.

    My disk is apparently GPT because when I run "sudo parted -l", it says "partition table: gpt".

    I have a CSM option in my BIOS, but enabling that doesn't give me a non UEFI option for my hard disk.

    I'm trying to do a clean install---no Windows.

    Thanks!

  9. #9
    Join Date
    Nov 2009
    Location
    Catalunya, Spain
    Beans
    14,558
    Distro
    Ubuntu 18.04 Bionic Beaver

    Re: boot-repair can't reinstall grub

    For clean install I would disable UEFI if possible and if you can do that use msdos table instead of gpt. If you decide to use gpt and non-uefi boot make sure you create a small 1MiB partition first with NO filesystem and the bios_grub flag on it. It's necessary for grub2 to install correctly on gpt disks.

    It might be some uefi issue with your machine and ubuntu. But if you can't disable uefi I guess you are stuck with it.

    Your boot info from post #1 seems correct. I have no idea what could be wrong.

    I would try the legacy boot + legacy install but that can only work if you find a way to disable uefi boot in bios.
    Darko.
    -----------------------------------------------------------------------
    Ubuntu 18.04 LTS 64bit

  10. #10
    Join Date
    Jan 2008
    Location
    France
    Beans
    Hidden!
    Distro
    Ubuntu Development Release

    Re: boot-repair can't reinstall grub

    Quote Originally Posted by pussinboots View Post
    Here's the last 30 or so lines before it hung. It was all pulse's after the "Boot EFI files" line.

    (..)
    => [[ PY ]] => Files in /mnt/boot-sav/sda2/boot/efi: /EFI/ubuntu/grub.cfg /EFI/ubuntu/grubx64.efi /EFI/ubuntu/shimx64.efi /EFI/ubuntu /EFI
    => [[ PY ]] => Boot EFI files in /mnt/boot-sav/sda2/boot/efi:
    Thanks, this helped. I think I found something. I uploaded a possible fix on the PPA: boot-repair 3.197~ppa39
    Please wait about 2hours, then update your boot-sav and boot-repair packages, and check if it still hangs?
    Last edited by YannBuntu; March 23rd, 2013 at 11:14 PM.

Page 1 of 3 123 LastLast

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •