1

I have the Lenovo recovery CD and started with a fresh install of Windows 7. I installed Ubuntu and GRUB was able to run both operating systems.

I tried to follow the Arch docs, but It's not clear when I should be chrooted into the new installation for running grub. Should /boot/grub/grub.cfg be in sda1 or sda4? Where do i run the 'chainload' command?

I tried the Boot Repair Disk, but it doesn't know how to handle the latest Arch commands.

The output of Boot Repair Disk is here: http://paste.ubuntu.com/24937724/

Can someone look to see where I went wrong and give instructions on how to start from scratch? When do I mount sda1? after I'm in chroot?

1

Be aware your system uses EFI boot style. Since you became confused about when to chroot, I present you a method of installing GRUB without.

  1. Boot a live Linux (the Arch installation medium will probably do in this case, explicitly change to a console if needed).
  2. Mount the target system partition with mount /dev/sda4 /mnt.
  3. Mount the target EFI system partition into the apropriate directory mount /dev/sda1 /mnt/boot/efi.
  4. Your current state features two instances of grub.cfg. I advise to remove /mnt/boot/efi/grub/grub.cfg. In theory, the grub.cfg can be placed virtually everywhere, but /mnt/boot/grub/grub.cfg is a standard location.
  5. Run grub-mkconfig -o /mnt/boot/grub/grub.cfg. This essentially is the same as running update-grub from within a chrooted environment. During the process, the os-prober component of grub-mkconfig should automagically detect the Windows installation and add it to the configuration.

    edit /etc/lvm/lvm.conf and change use_lvmetad=1 to use_lvmetad=0 execute update-initramfs -k KERNEL_VERSION -u ; sync

  6. Run grub-install --root=/mnt --target=x86_64-efi /dev/sda. To install the EFI variant of GRUB into the EFI system partition. With the --root parameter you tell grub-install where to look for the grub.cfg.

  • I get an error without running arch-chroot. When I chroot at the point that you say (thanks for that), I get a WARNING: Failed to connect to lvmetad. Trying to follow instructions from this answer askubuntu.com/questions/745218/… – McPedr0 Jun 25 '17 at 1:47
  • As far as I can tell from the Boot Info Script output from the original question, your setup does not include full system disk encryption. That is fine, the boot process would be more cumbersome with encryption. Please explicitly state the error you mention. – Hermann Jun 25 '17 at 11:35
  • /usr/bin/gurb-probe: error: failed to get canonical path of 'airootfs' – McPedr0 Jun 25 '17 at 14:54
  • I never encountered that problem before. unix.stackexchange.com/questions/251670/… suggests using grub-install --root-directory=/mnt --target=x86_64-efi /dev/sda instead of the by me proposed grub-install --root=/mnt --target=x86_64-efi /dev/sda. – Hermann Jun 25 '17 at 16:03

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.