I can't boot openSUSE Leap

I installed openSUSE Leap from a USBLive. After finishing successfully the installation process, I did not reboot. I did shutdown my laptop, I removed the USB and then, I turned on my laptop, I entered the BIOS, I changed the boot disks order to boot from the HDD first. But then, when my laptop boots up, it stops at the grub2 prompt (grub>).

Reading about this issue, I could understand that GRUB2 can’t find its configuration files.

Overview of my Disk and Partition-layout:


Disk /dev/sda: 698.7 GiB, 750156374016 bytes, 1465149168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: gpt
Disk identifier: C602CE13-BEAE-4F4A-82D2-94449262634C

Device                 Start            End       Sectors      Size   Type
/dev/sda1             2048      1050623     1048576     512M   EFI System
/dev/sda2        1050624    84951039    83900416      40G   Microsoft basic data
/dev/sda3   1452814336 1465147391   12333056     5.9G   Linux swap
/dev/sda4      84951040 1452814335 1367863296  652.3G  Microsoft basic data

Partition table entries are not in disk order.

Disk /dev/sdb: 7.3 GiB, 7803174912 bytes, 15240576 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x20ca2c8b

Device     Boot   Start        End  Sectors   Size  Id  Type
/dev/sdb1           3780     11339      7560  3.7M  ef  EFI (FAT-12/16/32)
/dev/sdb2  *      11340 9078783 9067444  4.3G  17  Hidden HPFS/NTFS


Model: ATA Hitachi HTS54757 (scsi)
Disk /dev/sda: 750GB
Sector size (logical/physical): 512B/4096B
Partition Table: gpt
Disk Flags: 

Number  Start      End        Size        File system     Name     Flags
 1           1049kB  538MB   537MB    fat32                             boot
 2           538MB   43.5GB  43.0GB   btrfs                primary  legacy_boot
 4           43.5GB  744GB   700GB    xfs                  primary
 3           744GB   750GB   6315MB  linux-swap(v1)


Model: Kingston DT 101 G2 (scsi)
Disk /dev/sdb: 7803MB
Sector size (logical/physical): 512B/512B
Partition Table: msdos
Disk Flags: 

Number  Start       End        Size       Type        File system  Flags
 1           1935kB  5806kB   3871kB   primary                       type=ef
 2           5806kB  4648MB  4643MB  primary                       boot, hidden, type=17

Well, I’ve been trying re-install grub2. From the bash shell, I did the following:


sudo mount /dev/sda2 /mnt

sudo moun --bind /dev /mnt/dev &&
sudo moun --bind /dev/pts /mnt/dev/pts &&
sudo moun --bind /proc /mnt/proc &&
sudo moun --bind /sys /mnt/sys

sudo chroot /mnt

Then when I type:


# grub2-mkconfig -o /boot/grub2/grub.cfg

but I get the following:


Generating grub configuration file ...
Found theme: /boot/grub2/themes/openSUSE/theme.txt
Found linux image: /boot/vmlinuz-4.1.12-1-default
Found initrd image: /boot/initrd-4.1.12-1-default
  /run/lvm/lvmetad.socket: connect failed: No such file or directory
  WARNING: Failed to connect to lvmetad. Falling back to internal scanning.
done

When I type:


# grub2-install /dev/sda

I get …


Installing for i386-pc platform.
grub2-install: warning: this GPT partition label contains no BIOS Boot Partition; embedding won't be possible.
grub2-install: error: filesystem `btrfs' doesn't support blocklists.

Well, I don’t know what to do, ¿Any help? …

Reinstall from scratch

Some questions:

  1. Is your system UEFI capable?
  2. Did you install as UEFI or as Legacy BIOS?
  3. Please provide the output from
ls /boot/grub2

On Tue, 08 Dec 2015 21:56:02 +0000, megawatt wrote:

> Reinstall from scratch

Not necessary - I would be more inclined to boot rescue mode from the
installation media, mount the partition with /boot and try reinstalling
the bootloader.

Note that you need to do a few things before you can run grub2-install.
I had to do:


mount /dev/sdb9 /mnt
cd /mnt
mount --bind /proc proc
mount --bind /sys sys
mount --bind /dev dev
mkdir mounts
mount --bind /mounts mounts
chroot .

Then you should be able to run YaST’s bootloader module or just use the
grub2 commands to install your bootloader.

Note that the first mount command will depend entirely on your
configuration. For me, / was on /dev/sdb9, but your system will probably
be different.

Jim


Jim Henderson
openSUSE Forums Administrator
Forum Use Terms & Conditions at http://tinyurl.com/openSUSE-T-C


Hi Jim. Thank you for you replay. Look I did the following:

joser@linux-wm32:~> sudo mount /dev/sda2 /mnt
root’s password:
joser@linux-wm32:~> cd /mnt/
joser@linux-wm32:/mnt> sudo mount --bind /proc proc
joser@linux-wm32:/mnt> sudo mount --bind /sys sys
joser@linux-wm32:/mnt> sudo mount --bind /dev dev
joser@linux-wm32:/mnt> mkdir mounts
mkdir: cannot create directory ‘mounts’: Permission denied
joser@linux-wm32:/mnt> sudo mkdir mounts
joser@linux-wm32:/mnt> sudo mount --bind /mounts mounts
joser@linux-wm32:/mnt> sudo chroot .
linux-wm32:/ # grub2-install /dev/sda
Installing for i386-pc platform.
grub2-install: warning: this GPT partition label contains no BIOS Boot Partition; embedding won’t be possible.
grub2-install: error: filesystem `btrfs’ doesn’t support blocklists.
linux-wm32:/ #

And /dev/sda2 is where is my root partition

joser@linux-wm32:/mnt> cd ~
joser@linux-wm32:~> ls /boot/
backup_mbr dracut initrd-4.1.13-5-default symvers-4.1.13-5-default.gz System.map-4.1.13-5-default vmlinuz-4.1.12-1-default
boot.readme grub2 message sysctl.conf-4.1.12-1-default vmlinux-4.1.12-1-default.gz vmlinuz-4.1.13-5-default
config-4.1.12-1-default initrd perl-BL_delayed_exec sysctl.conf-4.1.13-5-default vmlinux-4.1.13-5-default.gz
config-4.1.13-5-default initrd-4.1.12-1-default symvers-4.1.12-1-default.gz System.map-4.1.12-1-default vmlinuz
joser@linux-wm32:~> ls /boot/grub2/
backgrounds device.map device.map.old fonts grub.cfg grubenv i386-pc locale themes x86_64-efi
joser@linux-wm32:~>

any help? Tank you …


Hi nrickert](https://forums.opensuse.org/member.php/49759-nrickert) thank you for your replay.

  1. Yes my system is UEFI capable.

  2. I think I installed as a legacy BIOS.

  3. This my output


joser@linux-wm32:~> ls /boot/grub2/
backgrounds  device.map  device.map.old  fonts  grub.cfg  grubenv  i386-pc  locale  themes  x86_64-efi

Thank you again for your repay …

You might check the position of your boot flag on the device.

It is quite unlikely after reviewing your partition setup. Please boot from CD in EFI mode and repeat all steps, but do not forget also mount ESP on /boot/efi.

Then you might be better off installing for UEFI booting.

On the other hand, if you have other systems on that computer that use legacy booting, then stick to legacy.

  1. I think I installed as a legacy BIOS.

With legacy partitioning, if you put grub in the MBR, it uses the unassigned space just after the MBR.

With GPT partitioning, there is no unassigned space. So you need a bios-boot (sometimes called “bios-grub”) partition. I’ve been putting that in the space between sector 34 and sector 2047. You can create it with “gdisk” and probably with the latest “fdisk” (though I have not tried that).

  1. This my output

joser@linux-wm32:~> ls /boot/grub2/
backgrounds device.map device.map.old fonts grub.cfg grubenv i386-pc locale themes x86_64-efi

So you have at one time installed for UEFI booting (note the directory “x86_64-efi”). Probably your original install did that, then your reinstall of grub2 changed it to legacy booting. That’s part of the confusion.

On Wed, 09 Dec 2015 01:16:02 +0000, joser7 wrote:

> grub2-install: error: filesystem `btrfs’ doesn’t support blocklists.
> linux-wm32:/ #

That’s strange, I don’t recall seeing that with my system, and I’m also
using btrfs.

Doing a little searching around, I found some suggestions that if you’d
created a partition with btfs and then deleted it and recreated it, it
may still be being picked up by the grub2-install program.

Do you have a backup of the system? If you do, you might try some of
what’s suggested at https://www.linuxquestions.org/questions/linux-
software-2/btrfs-preventing-installation-of-grub2-4175511408/

Jim


Jim Henderson
openSUSE Forums Administrator
Forum Use Terms & Conditions at http://tinyurl.com/openSUSE-T-C

I could fix my boot issue. Thanks to the answers in this thread, I understood that my ESP partition was not mounted, which it is necessary to boot a system in EFI mode. I think the issue occurred because I had set my BIOS to provide Legacy booting support, because my USB flash is recognized by the BIOS if this option is enabled; so when I installed my new OS from the LiveUSB, it was installed in BIOS/CSM-mode. But as it said avidjaar in this thread, it was quite unlikely according to my partition setup after installation. Just, for some reason that I do not understand yet, my ESP partition was not mounted. So, I followed the avidjaar’s advice and I tried mount the ESP on /boot/efi, but that did not worke either for me.

I had to read many forums and blogs about this topic, fortunately I encountered the Rod Smith web page (http://www.rodsbooks.com/), and I had to read many of his posts to understand better how managing EFI Bootloaders for Linux works. Specially the articles, http://www.rodsbooks.com/linux-uefi/, http://www.rodsbooks.com/efi-bootloaders/index.html, were very helpfully, but still, nothing could fix my issue. So I tried again the avidjaar’s advice, and I boot from a LiveCD. That’s what I did, I installed my new opensuse from a LiveCD, and that works. Now, my system boots up successfully from EFI mode, the ESP partition is now mounted, and the issue is resolved, at least for me. It was a silly mistake but annoying, but it helped me to understand better this topic.
rotfl!

I appreciate if someone can explain to me why when I installed from the LiveUSB, the ESP was not mounted if the LiveUSB containing that partition, as seen in post # 1 of this thread. Thank you.