Install problem RL8.5 from USB, won't boot after install

Hi,
I am getting ready to move to Rocky from Scientific Linux, (another EL clone) as they decided to stop producing new versions after EL7.9. I have set up a bootable USB thumb drive with the DVD iso, and I am testing on a older HP Z200 SFF computer that I use as an installation testbed.
When I boot from the USB drive using UEFI secure mode, the install appears to work as expected, except the system will not boot after the install.
Some details:
USB drive was created using the dvd1 iso image using dd.
USB drive boots normally after using the boot menu to boot from this source. During install, the USB disk device shows up as sda, and the internal HDD shows up as sdb. I indicate that the install only use sdb as a device to install to, ignoring sda. I do a complete wipe of the sdb drive when installing, and ask for the bootloader to be installed on sdb. So far, OK. After the install, the system should reboot and boot from the internal HDD, but the boot fails with a message stating that there is no bootable drive in the system.
I also downloaded the minimal iso, and burned it to a dvd, which I then used to do a server+GUI network install. This did set up the boot drive correctly, as it now was listed as sda.
This was an issue in EL 7.x early in the release cycle, and there was a workaround where the bios names for the drives could be changed before the install, so the usb drive would be assigned as sdb instead of sda, but I cannot remember how to do it, and I cannot find any references on how to do it, either.
I also grabbed the minimal install iso and burned it to a dvd-r, which I used to do a network install, which did work well, including the setup of the UEFI boot.
Any suggestions?

I don’t have an answer to how to insure that the install disk is /dev/sda but I circumvent that issue by pre-partitioning at least the vfat efi partition. I use a boot disk with gparted and create a 500mb partition at either the beginning or end of the disk. Then I do the install and select that efi partition to be used but not reformatted.

I seem to remember the issue you describe being mentioned here on the forum in the recent past, but it was not the thread topic so hard to search for.

“I am testing on a older HP Z200 SFF computer that I use as an installation testbed.”

When you say “OLDER”, how old is old? I use a rescued HP ( Pavilion d4790y, running Windows Vista! ) that was sitting by the dumpster. It was totally DEAD!! so started to strip it for parts, but then so some strange reason decided to see if I could bring it back to life. I did!! I maxed it out with a handful of parts from my parts drawer, upgraded the CPU from a Duel core to a Quad Core, and upped the memory from 1 GB to 6 GB some from my infamous parts drawer, and 4GB (2x2GB of DDR2. RAM NEW!! Between the Quad Core CPU (NEW if you can believe it – from China, but took 4.5 months to get here!!!). and the 4 GB of DDR2 RAM I spent about $35 -$50) . It looks nothing like the clunker I pulled from the next to the dumpster!! Jaguar’s purpose in life is as a sandbox aka “kitty litter” box aka “test bed”. As an aside you would LOVE my sister: All she buys are Small Form Factor computers – which I refer to as Tinker Toys. Me?!? I HATE them as they are a PITA to work on/in!!

Now Back to our regularly scheduled show: As I was saying, depending on how OLD is OLD, which I will define as running Windows 7 or before, the best thing to do with that box is to turn it into a STRICT LINUX BOX – NO WINDOWS!! If you do that you can simplify your life by setting the BIOS into Legacy Mode and forget all this jazz about UEFI. UEFI is ONLY NEEDED for a WINDOWS MACHINE. The BIG difference here is that during your install phase, and you start dividing up the drive into partitions instead of having a /boot/efi (I THINK) set it to /boot and allocate at least 2-3 GiB in size. Then finish partitioning as you see fit (I use a Classic Partitioning Scheme but some people use a 50: 50 approach of some Classic Partitioning and some LVM.) Doing a complete wipe of the HDD (or SATA drive is a smart thing. I use GParted to Delete all the partitions and you can be SURE that it is a CLEAN drive.)

There might one other limitation: How much RAM do you have?? Some of these OLD machine came with 1, and if you were lucky 2 GB of RAM.

If this sounds like the voice of experience: I just finished installing RL 8.5 on jaguar. Even with 6GB of RAM and a Quadcore CPU it is slower than a snail – but it DOES run!!

A couple words of note: Unless you are a pro with "Minimal Installs ( I am NOT) choose Sever + GUI as the package install – you can always go back and backfill other packages, but starting out with NO GUI is a killer. Make sure that you have DHCP turned ON (Otherwise you will have no network, and – as I just discovered with the network is not enabled the thing that goes round and round goes on and on until it times out and starts giving you a whole lot of ERROR messages, and it will NOT ever get you to the login page.

It sounds as though you are on the right trail. If this indeed an OLD machine skip the UEFI boot and change it to a Legacy boot by changing the /boot/efi => /boot ; make sure you have around 8 GB of RAM – you can get by with a lesser amount but I’m having problem with 6 GB, and finally make sure the DHCP is turned ON (don’t leave it off as it then expects you to MANUALLY set up the network).

Hope this helps.

D’ Cat

Not sure it would make any difference but there are tools for creating bootable USB drives that can yield quite different behavior opposed to using dd. On Fedora for example you can open the file browser, navigat to the ISO image, right click on it, select Open With Other Application and then Disk Image Writer. Then select the USB drive and click “Restore”. Eject and now you have a live bootable image. Maybe that would yield different results.

2 GiBHi D’Cat
This boxen is a pizza box format, from 2011, with 4Gb ram. It will boot in secure mode from the USB, and it appears to do fine through the install process, except it does not install the bootloader in the MBR of /dev/sdb, but instead uses the grub that is on the usb drive, which it sees as sda.
I prepared the drive to force it to be treated as a bare drive by using dd to zero out the first MB of the drive while booted using the live image. I had it create a gpt partition table, a total of 7 partitions. Did
Install of the server+GUI, plus a few tools. Install looks good, but no bootloader was installed, and when the reboot was attempted, there was no grub prompt or anything.
Are there any kernel options that can be used on the preinstall boot to swap devices sda and sdb? Alternatively, is there a way to force installation of the grub2 bootloader on sdb?
Any pointers would be useful.
Thanks

faitjx

IF I read that correctly, my one comment would be “OUCH”. I’m having problems running RL 8.5 on a similar computer from that same era that I then hacked and installed a quad core CPU and up the RAM from 1 GB to 6 GB. It is a former M$ HP WS. Now all it runs is Linux – ZERO Windows. With 4 GB of RAM it may be painfully S-L-O-W. (CentOS 7 with 3 GB took forever to boot ergo the reason I boosted it to 6 GB, and am seriously thinking of Maxing it out at the full 8 GB).

I have one other computer – also very OLD – that has 2 HDD’s (spinning rust – not SSD’s) that had 2 OS’s on it that had the GRUB (not GRUB2, but GRUB) menu on one drive while the the OS was on the other drive. Yes I can still boot that that machine. GRUB was relatively easy to hack, GRUB2 far more difficult, and with RHEL 8.5 and its offspring even more difficult because RHEL (and RL, and Alma Linux, etc.) 8.5 instead of using straight GRUB2, now shunted the boot option to /boot/loader/entries In short if GRUB is not correctly configured to go looking for the boot process in /boot/loader/entries it will never find the files it needs to boot from.

What is the best thing for you to do? The BIG question that needs to be asked is this a dual boot machine or not? If NOT then the fastest and easiest solution is to erase the ENTIRE drive you plan to install RL on using something GParted – I mean scrub the ENTIRE DISK so that there is nothing left on it and then do a complete reinstall. After you do that go into BIOS and set it up as a LEGACY BIOS – NOT UEFI or EFI – “Secure Boot” is a “Windows Thing”, and you ONLY need that IF you are dual booting and the other OS is Windows XYZ. With your BIOS set for Legacy, and you CLEAN and EMPTY drive, that your install media and start the install over again, however this time the very first partition you should create is /boot and allocate 2-3 GiB (I use 3 GiB) --not /boot/efi or anything thing else. The second partition you should create is /root. The third partition you should create is /home.

I go to great lengths to put the entire install on a single drive, as it limits the places I need to look if something goes WRONG. It also makes backing up the entire drive a piece of cake. Sometimes that is not possible and you need to spread out the install over two or more drives. There might be one utility that can bail out your current install and that is called grub-customizer. If you have a secondary Linux running grub-customizer will go out and find any other OS’s out there and then you can create a custom menu. If all else fails you can backdoor your way into RL In your case it may find where the boot installer for RL is located and you can access it that way. MAYBE!
Beyond that you start getting into serious hacking. You need to know where the /boot partition is located and the MBR are located (I will assume this in /dev/sda) to check for sure run the command fdisk -l from a konsole. It will Identify all the drives present and the one from which it is trying to boot from. Some GURU might have some way to do what you are trying to do, but it sure ain’t me.

Summation:

  1. IF this drive is going to hold nothing but RL, solve the problem by following the path of least resistance: A) Wipe the entire drive so it is EMPTY B) Go into BIOS and set it for LEGACY BIOS C) Do a complete REINSTALL from scratch making sure the the very first partition you create is /boot (NOT /boot/efi). D) the second and third partitions should be /root and /home in that order, and after that as many partitions as you choose. As to SIZE?? I usually use 3 GiB for /boot, about 20-25 GiB for /root, and my single largest partition is /home which can between 150 - 350 GiB depending on the size of the drive. As a Side Note: I usually use a Classic Partitioning Scheme – sometimes called a “Custom”, while a lot of people use LVM and allow the computer to do the work for them. The choices you make here matter. There are +'s and -'s to each way. As to the File System, I use Ext4. Why? If the fecal matter hits the rapidly revolving air circulating device using fsck can usually fix the problems with ease. Again those are MY choices, they may not be YOURS.

  2. If you want to see if you can rescue the current install try downloading a copy of Grub-customizer. You might have a way to backdoor your way into the install.

  3. Beyond that find yourself a good GURU who can mutter incantations that can fix anything.

Final words (besides “Go with God”): See if you can bump up the RAM to its full 8 GB. I’m not sure what the HW requirements are for RL but from personal experience while you might be able to run in 4 GB, it will be painfully SLOW. 8 GB would be my recommendation.

The “Secure Boot” is only on EFI mode, not in legacy mode.

  • In EFI mode the system seeks ESP (EFI System Partition) from disks that have GPT. The sector 0 is not looked at.
  • In legacy mode system attempts to load first stage of bootloader from sector 0 (and disks usually have MBR)

The USB should have both, so it can boot in both modes. If you do boot in EFI mode, then the installer should aim to set up GPT – separate /boot/efi for ESP, etc. If you do boot in legacy mode, then MBR.
I would use EFI, if the system has it.

IIRC, I have never seen the USB as “disk” in the interactive installer’s partitioning tool.

I eventually punted on using secure mode for this system, and set it up using Legacy mode. As it was already partitioned with GPT, it requires a small (1MiB) biosboot partition, but after that, everything seems to work. As far as memory goes, this system seems to run just fine with 4GB ram, as long as I keep the number of services, etc. reasonable.

… It still would not hurt to upgrade the RAM – if you can – to a full 8 GB. You will find that it runs far better. Assuming it is running DDR2, you can probably upgrde it for for a song – you can SING? Yes? At most you buy or find 4 sticks of 2 GB SIMMS – even adding 2 sticks would be better and you must have some of those floating around somewhere.

Hello all,

I tried install 8.6 (boot & dvd1) & 8.5 (minimal) from usb created either with rufus, balenaetcher or dd and it ended unsuccessful with the following display after boot:
Invalid image
Failed to read header: Unsupported
Failed to load image: Unsupported
start_image() returned Unsupported

Enabling/disabling secure boot (UEFI) didn’t change the behaviour.

Nevertheless, I tried rocky 8.4 dvd1 iso with dd and I could use the usb to boot and install rocky 8.4 on my system.

Regards

2022-06-25 Second update. I continued to work on this, and found that it is possible to force the partitioning to make a bootable solution. As I am working on installation methods for a bunch of servers, I found that if I set the kernel options for installation to force use of a gpt disk label, and then in the custom partitioning create both a tiny (2Mb) biosboot partition and the boot/efi EFI partition as less than 500Mb, along with the normal /boot, /, and home partitions as xfs, then I could force the boot as either EFI or BIOS with the bios boot option of either Legacy Boot only or Secure Boot.
To force the use of gpt for the partition table, on the kernel line for GRUB2, add inst.gpt to the kernel options. See Chapter 16, Boot Options for RHEL 8
I then created a kickstart file that uses a %pre script to set up the partitioning for use to set up our systems going forward with as little pain as practical. The Kickstart file is shown below:

#version=RHEL8
#
eula --agreed
# Use graphical install
graphical 
# Network information
network  --bootproto=dhcp --device=link --ipv6=auto --activate
network  --bootproto=dhcp --hostname=rocky.localdomain
#
%include /tmp/parts.cfg
#  Installation sources 
harddrive  --partition=LABEL=ROCKY-8-5-X --dir=/
repo --name="AppStream" --baseurl=file:///run/install/repo/AppStream
#
# Keyboard layouts
keyboard --xlayouts='us'
# System language
lang en_US.UTF-8

%packages
@^graphical-server-environment
@development 
@graphical-admin-tools
@network-file-system-client
@rpm-development-tools
@system-tools
kexec-tools
gnome-tweaks
python3-pip
-insights-client
%end


# Run the Setup Agent on first boot
firstboot --enable

# System timezone
timezone America/Chicago --isUtc

%addon com_redhat_kdump --enable --reserve-mb='auto'

%end

%anaconda
pwpolicy root --minlen=6 --minquality=1 --notstrict --nochanges --notempty
pwpolicy user --minlen=6 --minquality=1 --notstrict --nochanges --emptyok
pwpolicy luks --minlen=6 --minquality=1 --notstrict --nochanges --notempty
%end
%pre --interpreter=/usr/libexec/platform-python
from pathlib import Path
lines =  Path('/dev/disk/by-id').glob('*')
devs = {}
for l in lines:
	s=l.as_posix()
	if s.startswith('/dev/disk/by-id/wwn-') and (not s.endswith('-part',-6,-1)):
		d = l.resolve().as_posix()
		devs[d] = s
	if s.startswith('/dev/disk/by-id/usb-Kingston') and (not s.endswith('-part',-6,-1)):
		source = l.as_posix()
fd = open('/tmp/parts.cfg',mode='w')
klst  = list(devs.keys())
klst.sort()
dest=devs.get(klst[0])
print('ignoredisk --drives=%s'%(source),file=fd)
print('bootloader --location=mbr   --drive=%s'%(dest),file=fd)
print('clearpart --all --initlabel --disklabel=gpt --drives=%s'%(dest),file=fd)
# Disk partitioning information
print('part biosboot --fstype="biosboot" --size=2 --ondisk=%s'%(dest),file=fd)
print('part /boot/efi --fstype="efi" --size=400 --ondisk=%s'%(dest),file=fd)
print('part swap  --fstype="swap" --hibernation  --ondisk=%s'%(dest),file=fd)
print('part /boot --fstype="xfs" --label=BOOT --size=2000   --ondisk=%s'%(dest),file=fd)
print('part /     --fstype="xfs" --label=ROOT --size=100000 --ondisk=%s'%(dest),file=fd)
print('part /var  --fstype="xfs" --label=VAR  --size=100000 --ondisk=%s'%(dest),file=fd)
print('part /opt  --fstype="xfs" --label=OPT  --size=100000 --ondisk=%s'%(dest),file=fd)
print('part /home --fstype="xfs" --label=HOME --size=100000 --grow --ondisk=%s'%(dest),file=fd)
fd.close()
%end

This gave a stable, reproducible install on all of the various hardware that I tested on, as long as it had a 500Gb disk for the install.