Workstation is unable to boot after successful install

Hello Geekos,

Short Intro:
Installation using a USB was smooth and I was up and running within no time; however, after shutting down, removing the USB, and starting up the computer again, it complained about not finding a way to boot the computer. I have to use the USB to boot my system, and I have been unsuccessful in changing this.

The longer version:
I just received a new workstation for work yesterday, and I plan to install OpenSUSE 13.2 using a USB installer. The computer has one PCIe SSD and one regular SATA HDD; I plan on partitioning them similar to the way mentioned in this thread. Basically, the OS (/boot, /, and /opt) is on the SSD and /home is on the HDD. All drives are EXT4 except for the small amount of swap on the HDD.

This is what the output of <lsblk> shows:


NAME   MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
sda      8:0    0   1.8T  0 disk 
├─sda1   8:1    0    10G  0 part /var
├─sda2   8:2    0    10G  0 part [SWAP]
└─sda3   8:3    0   1.5T  0 part /home
sdb      8:16   0 238.5G  0 disk 
├─sdb1   8:17   0     1G  0 part /boot
├─sdb2   8:18   0   125G  0 part /
└─sdb3   8:19   0   100G  0 part /opt
sdc      8:32   1  14.5G  0 disk 
├─sdc1   8:33   1     4M  0 part
└─sdc2   8:34   1   4.4G  0 part
sr0     11:0    1  1024M  0 rom  

The /dev/sda is the secondary HDD, /dev/sdb is the primary SDD, and /dev/sdc is the USB. All were installed using UUID.

I have tried changing various BIOS options (e.g. changing SATA controller from RAID to both ACHI and ATA), as well as messed around in the installation procedure (e.g. yes/no install of GRUB into MBR) with no avail. I can confirm that during the installation, the screen printed out that the order of the disks was /dev/sdb, /dev/sda, /dev/sdc, so I was pretty sure the boot was installed on the correct drive.

Conclusion:
I really have no idea what I could/should be doing differently. Does anyone have any ideas of what I could try to fix this problem?

Please show exact message - it matters. You can simply make a photo and attach.

Note that installing to mbr should not be done that machine has EFI BIOS and is advisable to install in EFI mode Also you havea separate boot which is OK butit is on the second drive. Which confuses me and may also confuse the computer. If installing in legacy mode you should boot the installer in legacy mode. If installing in EFI mode you want to boot the installer in EFI mode. I recommend EFI where you won’t have to deal with any possible legacy hiccups in your EFI BIOS and will make GPT partitioned disks which have advantages in that there are no extended partition and you can have about all you can deal with on one drive.

In EFI you will have (need) an additional small FAT formatted partition mounted as /boot/efi.

If you stick to legacy you need to have /boot on the boot drive which also has MBR code and is normally sda1

Howdy Everyone,

Thanks for responding so quickly, here are the answers to your questions:

@arvidjaar:
If I remove the USB and start the machine, the result is a black screen with the following error message:

No Boot Device Found. Press any key to reboot the machine.

After re-inserting the USB the OpenSUSE welcome screen pops up (the one with the CD/DVD and the Geeko). I am currently using the “Boot from Hard disk” option, but there must be a better way.

@gogaltharp:
Currently my BIOS is set in Legacy mode, with UEFI and secure boot disabled. Only with the SATA controller option “ATA” did the SSD come up as drive /dev/sda, with all other options it consistently comes up as /dev/sdb. Is this something I need to fix if I want to boot from the SSD?

I think your problem it’s hard disk boot priority, go in bios and see what hard drive is setup as the first boot device, if you installed / and /boot in the ssd but hdd is the first boot device a simple change in boot priority should fix this.
ps where did you install grub did you install it in the mbr, if you are booting legacy and there is no boot code in mbr you will get this problem

Hi there,

@I_A: I made sure that the boot order was the following before installing:


Flash drive
CD/DVD rom
SSD 
HDD

I did try to install the boot loader onto the MBR along with in /boot/, but that did not solve the issue. Do I need to only install it in one of the places for it to work?

Second question, possibly very ignorant: Is it possible to install GRUB after you have installed the OS? Since there is still a /boot/ directory, I could just overwrite it, no?

Cheers,
c

Yes, of course, but before doing it it should be known whether your system boots using legacy BIOS or UEFI. This requires different grub flavors and different disk partitions. The error message you quoted could mean that either system tries to boot using legacy BIOS and there are no executable code in MBR or that system tries to boot in UEFI mode (and your partitions do not list ESP, so UEFI boot is likely impossible).

The /boot directory contains the kernel + grub + initrd stuff. It is absolutely required. But it is optional to be on a separate partition. But since you installed it that way don’t change it you don’t want to reinstall

Be sure that the EFI boot menu is set to the correct location and boot type.

if that is not it then install generic boot or grub2 in the MBR of the boot drive which we are assuming is sdb now.

Boot a live openSUSE disk/USB run yast-bootloader be sure things are pointing to the correct drive and set it to install to the mbr. It probably better to install generic and set a boot flag on the /boot partition

Or you could download and use a supergrub distro and use that which is setup for just this kind of thing

On 2015-07-07 18:46, cbcoutinho1 wrote:
>
> Hi there,
>
> @I_A: I made sure that the boot order was the following before
> installing:
>
>
> Code:
> --------------------
>
> Flash drive
> CD/DVD rom
> SSD
> HDD
>
> --------------------

But what is the current order?
Maybe it is still trying to boot from the flash drive first.


Cheers / Saludos,

Carlos E. R.

(from 13.1 x86_64 “Bottle” (Minas Tirith))

Hey everyone,

I just double checked all the settings you all mentioned and can confirm the following:
– The computer is currently booting using the ‘Legacy’ option as opposed to UEFI
– The current book sequence is USB, CD/DVD, SSD, Onboard NIC (Something from Dell), Diskette Drive
– Using YaST2 - Boot Loader, I can see that the boot loader is GRUB2 (Not GRUB2-EFI), and the location is only the Boot partition
– Using YaST2 - Boot Loader, I can also see the disk order is still /dev/sdb, /dev/sda, and /dev/sdc (USB drive). The USB drive will be gone once this issue is resolved.

@gogaltharp:
1) What is the EFI boot menu? Is that for UEFI or legacy systems, or is it unrelated?
2) If the answer is to just reinstall GRUB2 or a generic boot loader and give it a /boot flag, how is that different than fixing the current /boot/ partition?

@robin_listas:
To test whether a proper boot loader was installed, I disconnected the USB and started up the machine. That is where this whole problem started.

From your combined comments, it seems to me that I should install either GRUB2 or a generic boot loader using YaST into the MBR. This should theoretically force the machine to boot using GRUB2 before anything, correct? Why is this better than installing it into the MBR using the OpenSUSE installer, which I already tried without success?

See image below for current boot settings. Currently, in YaST2 - Boot Loader, ‘Boot from Master Boot Record’ is un-selected; however, the generic boot option is. Does this mean the generic boot is already in the MBR?

http://i.imgur.com/STetpmw.jpg?3

Now I’m really surprised. It does indeed look like YaST lost ability to explicitly select bootloader device. In the past it was possible to tell “use /dev/sda” or “use /dev/sdb3”. Could you run https://github.com/arvidjaar/bootinfoscript/raw/master/bootinfoscript and upload result to http://susepaste.org/ ?

it does seam that you are booting in legacy (mbr) mode and there is no boot loader in the disk’s mbr
when installing you shuld have checked boot from Master Boot Record.
Installing the grub in the /boot partition is only useful if you alredy have another bootloader in the mbr
In short just check the box that says Boot from Master Boot Record

Howdy everyone,

I ran the bootinfoscript you linked and uploaded the result here. I am only barely understanding the output in this file, but to me it looks like there is in fact a boot loader (generic or GRUB?) on /dev/sdb.

I did mention that /dev/sdb was a PCIe SSD drive, correct? I’m not sure if that’s worth re-stating, but since I have used one before, maybe it is making the difference.

Well it is confusing because sda is normally the boot drive and is where the installer will put grub2/generic MBR as a default. If you put a generic boot loader in the MBR of sdb then you also need a boot flag on /boot partition

show us fdisk -l

that is a lower case L not a one

There is no harm in having grub2 in both the MBR and the partition with /boot ( note normally this is root )

You have an EFI BIOS it emulates legacy. But all thing have to agree. The EFI boot menu controls the boot even for legacy since in theory you can have a hybrid system (I don’t recommend it because it truly is complicated, this is not).

according to the screen you have generic MBR so you must have a boot flag on the /boot partition

This may have been missed because of you non standard set up

On 2015-07-07 23:06, cbcoutinho1 wrote:
>
> Hey everyone,
>
> I ran the bootinfoscript you linked too and uploaded the result ‘here’
> (http://susepaste.org/2221972f). I am only barely understanding the
> output in this file, but to me it looks like there is in fact a boot
> loader (generic or GRUB?) on /dev/sdb.

Yep. But this will only boot IF sdb is the first disk to try in the
BIOS, and Linux is correctly installed in that disk.

let’s see that script output…

=> No boot loader is installed in the MBR of /dev/sda.
=> Syslinux MBR (4.04 and higher) is installed in the MBR of /dev/sdb.
=> Syslinux MBR (4.04 and higher) is installed in the MBR of /dev/sdc.

I see that you have grub2 installed on sdb1. sdb has GPT, not
traditional partitioning. This may confuse things, as you are booting in
legacy mode.

sdb1 should be marked as bootable, and I think it is not. This is what
you should try first.

sdc has standard partitions.

sdc2 is marked bootable, but it is NTFS. Windows, I guess, is there. But
wait, blkid says it is a DVD, the openSUSE 13.2 DVD? i don’t understand.


Cheers / Saludos,

Carlos E. R.

(from 13.1 x86_64 “Bottle” (Minas Tirith))

sdb has GPT partition table and conventional boot loader in MBR. It cannot work together. Conventional boot loader expects traditional MBR partition table with active partition. As it is new installation it is easier to reinstall. If you want to install bootloader in /boot, you must initialize disk as MBR. If you want to use GPT, you must install bootlader in master boot record, but then you also need additional small partition of type “BIOS boot” and size of several MB. Not sure if YaST is smart enough to offer it, especially after manual partitioning. Partition needs not be formatted or mounted.

P.S. Something is strange here





  1.     Boot sector info:  Grub2 (v1.99) is installed in the boot sector of sdb1 
  1.                        and looks at sector 271416 of the same hard drive for 
  1.                        core.img. core.img is at this location and looks in 
  1.                        partition 132 for . 



Was it my bootinfoscript of from SourceForge? If it was my version, could you please run it once more, then tar the /tmp/BootInfo-random-characters directory and make it available? I would like to look why it misdetects grub.

Howdy everyone,

@arvidjaar:
You are right, the script I ran was just the first google hit of <bootinfoscript>. Running your specific script gives the following output here. If I need to tar the files still, please let me know. Could I then send that to you as a private message?

I only want to reinstall the system if I can make sure that the problem is fixed, and so far I am not confident this is solved. Would it be better to re-instate UEFI and then reinstall OpenSUSE, or could I leave the legacy option as is?

@gogaltharp:
I ran the script <fdisk -l>, and the output can be found here. True to your word, it seems my /dev/sdb1 disk was installed in EFI, which I cannot really understand why. I confirmed that the BIOS was in Legacy mode before installing OpenSUSE. Did I make a mistake here, or is the problem coming from the fact that the SSD is in /dev/sdb?

@robin_listas:
The third drive, /dev/sdc, is a USB drive with the OpenSUSE 13.2 iso installed on it. It was partitioned using OpenSUSE’s imagewriteer in a virtual machine. I hope I am explaining myself properly, I don’t want to be confusing

No need, it correctly returns grub information:





  1.     Boot sector info:  Grub2 (v2.00) is installed in the boot sector of sdb1 
  1.                        and looks at sector 271416 of the same hard drive for 
  1.                        core.img. core.img is at this location and looks for 
  1.                        (,gpt1)/grub2. 



I only want to reinstall the system if I can make sure that the problem is fixed, and so far I am not confident this is solved.

Not sure what will make you confident but it is your system and your decision. I have nothing to add to discussion and wish you good luck.

It is a bug in installer which will incorrectly mark boot partition as ESP even on legacy platform. Bug is fixed in the meantime in Factory/TW.

@arvidjaar:
I really appreciate your help, this would not be possible without you. What I meant to say was that I am not sure what I need to do to fix this issue, I didn’t mean that your answers are inadequate. This is what I gather from our discussion:

– /boot is correctly installed on /dev/sdb1 using GRUB2, not GRUB2-EFI; however, it has no boot flag (seen in <fdisk -l> output)
Is it possible to explicitly set this flag to boot without reinstall?
Can I mount the /boot partition to have this explicit boot flag?

– Although BIOS says boot using ‘Legacy mode’, OpenSUSE was installed using UEFI or EFI (as seen in <fdisk -l> output)
This is apparently a bug, although not in Factory/TW. I prefer to use OpenSUSE because I’ve never tried those systems, I hope that is possible.

– Both disks are GPT. I’m not sure where I set this, it may have been default or built into the drives. The generic MBR does not work with this disk type.
What do I do about this? Will this work by switching to (U)EFI?

Based on your advice it seems the best avenue would be to set Booting from Legacy to UEFI, and then reinstall OpenSUSE 13.2 using GRUB2-EFI because the installer expects an EFI version of GRUB as opposed to legacy.

Could you please confirm all of this before I reinstall my system?