[Solved] GRUB os-prober seems to hang during install

Ask for help with issues regarding the Installations of the Debian O/S.
Post Reply
Message
Author
Ravi Joshi
Posts: 23
Joined: 2015-10-03 16:56
Has thanked: 7 times

[Solved] GRUB os-prober seems to hang during install

#1 Post by Ravi Joshi »

I am trying to install from downloaded 'debian-12.7.0-amd64-DVD-1' iso.
On all the three install attempts, installer is stuck at finding other operating systems, which is 'os-prober, I presume'.
There is no way to escape out of it. Can someone help?
TIA
Last edited by Ravi Joshi on 2024-10-10 10:18, edited 1 time in total.

mrmazda
Posts: 500
Joined: 2023-06-02 02:22
Has thanked: 14 times
Been thanked: 63 times

Re: GRUB os-prober seems to hang during install

#2 Post by mrmazda »

How much time did you allow the hang to continue before giving up waiting on it?

Do you have any other operating systems? If you do, and Windows is one of them, be sure to boot Windows, then reboot, not shutdown or sleep, but when rebooting, select to boot something other than windows, a USB stick if need be. When Windows is improperly configured, shutting it down leaves its filesystem(s) in a state inaccessible to Linux.

I don't know whether the Bookworm installer is configured to deal with BTRFS filesystems used by default or option with various other distros. It may require some investigation. Presumption of support where support is actually lacking could be responsible for such a hang.

Ravi Joshi
Posts: 23
Joined: 2015-10-03 16:56
Has thanked: 7 times

Re: GRUB os-prober seems to hang during install

#3 Post by Ravi Joshi »

mrmazda wrote:- How much time did you allow the hang to continue before giving up waiting on it?
- Do you have any other operating systems?
- I don't know whether the Bookworm installer is configured to deal with BTRFS filesystems used by default
It hangs forever. At least 15 min. I had to deal with this step during 3 failed install attempts.
It has Arch which boots fine. In fact, I logged into arch, recreated grub.cfg. Arch's grub detects Debian and adds an entry. But upon starting debian, it now hangs in apparmour thing.
I am using ext4 & not BTRFS from debian installer.

One more thing I noticed in debian installer is that it never asked me if I wanted to install grub or where - this option you generally see when installing linux.

mrmazda
Posts: 500
Joined: 2023-06-02 02:22
Has thanked: 14 times
Been thanked: 63 times

Re: GRUB os-prober seems to hang during install

#4 Post by mrmazda »

If installing in UEFI mode and exists already an ESP, you didn't designate to install an additional ESP, and the existing ESP was found adequate in size, I would expect the installer to use the existing ESP, which IME would be the best option if you were asked where.

About the hanging in apparmour, all I can suggest is booting Arch or some other Linux, then chrooting into Bookworm to troubleshoot, possibly to create a new boot entry in UEFI BIOS using efibootmgr and/or other Bookworm tools for apparmour.

Aki
Global Moderator
Global Moderator
Posts: 3927
Joined: 2014-07-20 18:12
Location: Europe
Has thanked: 108 times
Been thanked: 517 times

Re: GRUB os-prober seems to hang during install

#5 Post by Aki »

Hello,
Ravi Joshi wrote: 2024-09-27 13:57 I am trying to install from downloaded 'debian-12.7.0-amd64-DVD-1' iso.
On all the three install attempts, installer is stuck at finding other operating systems, which is 'os-prober, I presume'.
There is no way to escape out of it. Can someone help?
If the computer seems to hang, can you press ALT-F4 or CTRL-ALT-F4 and take a look at the console messages from the Debian installer? If yes, can you report the messages printed on the screen?

Can you share a screenshot when the Debian Installer hangs ?
⢀⣴⠾⠻⢶⣦⠀
⣾⠁⢠⠒⠀⣿⡁ Debian - The universal operating system
⢿⡄⠘⠷⠚⠋⠀ https://www.debian.org
⠈⠳⣄⠀

Ravi Joshi
Posts: 23
Joined: 2015-10-03 16:56
Has thanked: 7 times

Re: GRUB os-prober seems to hang during install

#6 Post by Ravi Joshi »

@mrmazda The installer seems to choose existing ESP.
@Aki Please see attached image from 4th screen
I am not sure what mistake I am making. I've used manual type of disk partitioning, having selected root and swap partitions correctly.
Attachments
screen2.jpg

Aki
Global Moderator
Global Moderator
Posts: 3927
Joined: 2014-07-20 18:12
Location: Europe
Has thanked: 108 times
Been thanked: 517 times

Re: GRUB os-prober seems to hang during install

#7 Post by Aki »

Hello,

When the installer hangs after it is started with the debug option, press ALT-F2, open a console and the copy the file named /var/log/syslog to an external mounted ext4 formatted disk.
⢀⣴⠾⠻⢶⣦⠀
⣾⠁⢠⠒⠀⣿⡁ Debian - The universal operating system
⢿⡄⠘⠷⠚⠋⠀ https://www.debian.org
⠈⠳⣄⠀

mrmazda
Posts: 500
Joined: 2023-06-02 02:22
Has thanked: 14 times
Been thanked: 63 times

Re: GRUB os-prober seems to hang during install

#8 Post by mrmazda »

Can you show us output of parted -l or fdisk -l?

Ravi Joshi
Posts: 23
Joined: 2015-10-03 16:56
Has thanked: 7 times

Re: GRUB os-prober seems to hang during install

#9 Post by Ravi Joshi »

parted -l output at http://0x0.st/X6r1.txt

/var/log/syslog at : http://0x0.st/X6rx.txt

Is there a way to prevent grub installation, or at least os-prober?
Last edited by Ravi Joshi on 2024-10-09 17:06, edited 2 times in total.

mrmazda
Posts: 500
Joined: 2023-06-02 02:22
Has thanked: 14 times
Been thanked: 63 times

Re: GRUB os-prober seems to hang during install

#10 Post by mrmazda »

I should have asked only for fdisk -l. Please paste it here in thread, not elsewhere.

Ravi Joshi
Posts: 23
Joined: 2015-10-03 16:56
Has thanked: 7 times

Re: GRUB os-prober seems to hang during install

#11 Post by Ravi Joshi »

mrmazda wrote: 2024-10-09 16:52 I should have asked only for fdisk -l. Please paste it here in thread, not elsewhere.
Sorry. Here it is.

Disk /dev/sda: 238.47 GiB, 256060514304 bytes, 500118192 sectors
Disk model: FORESEE 256GB SS
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: gpt
Disk identifier: EB615E0E-052F-4F55-AB64-86162865E8B0

Device Start End Sectors Size Type
/dev/sda1 2048 206847 204800 100M EFI System
/dev/sda2 206848 239615 32768 16M Microsoft reserved
/dev/sda3 239616 201533439 201293824 96G Microsoft basic data
/dev/sda4 201533440 294283263 92749824 44.2G Linux filesystem
/dev/sda5 294283264 302671871 8388608 4G Linux swap
/dev/sda6 302671872 433743871 131072000 62.5G Linux filesystem
/dev/sda7 433743872 500115455 66371584 31.6G Microsoft basic data

mrmazda
Posts: 500
Joined: 2023-06-02 02:22
Has thanked: 14 times
Been thanked: 63 times

Re: GRUB os-prober seems to hang during install

#12 Post by mrmazda »

I was hoping that knowing the partitioning in detail would help me decipher the os-prober debug messages, but no such luck. :(

I have an affinity for NET installs. You might consider giving that a try. It minimizes risk of any bugaboo on the installation media - much much less to read from it.

Make sure you boot whatever installer you boot in UEFI mode. You can ensure that happens via BIOS setting to disable CSM (legacy/MBR) boot support if it hasn't been done already.

Aki
Global Moderator
Global Moderator
Posts: 3927
Joined: 2014-07-20 18:12
Location: Europe
Has thanked: 108 times
Been thanked: 517 times

Re: GRUB os-prober seems to hang during install

#13 Post by Aki »

Hello,

I'm not sure if the installer "hangs" because of the os-prober script, even if it is the last output on the screen.

During the Debian Installer process, the os-prober script is installed/started on behalf of the grub-installer (which is responsible for installing grub2).

Therefore, I assume that your Debian installation is almost complete, except for the grub2 boot loader.

So you can use the Debian Installer to:
  • boot in "rescue mode" (menu "Advanced" > menu "Rescue mode")
  • select the root partition (activating the chroot)
  • open a shell (character console) in the root partition
  • install grub2 manually (from the command line of the shell)
This should also give you more control when installing grub2, also for troubleshooting purposes.

If your computer boots with UEFI enabled, here you can find here general instructions: Hope this helps.
⢀⣴⠾⠻⢶⣦⠀
⣾⠁⢠⠒⠀⣿⡁ Debian - The universal operating system
⢿⡄⠘⠷⠚⠋⠀ https://www.debian.org
⠈⠳⣄⠀

Ravi Joshi
Posts: 23
Joined: 2015-10-03 16:56
Has thanked: 7 times

Re: GRUB os-prober seems to hang during install

#14 Post by Ravi Joshi »

@Aki , in all install attempts, I had waited roughly 300 seconds for os-prober to complete. But upon one more attempt in which I gave it roughly 10 minutes, the os-prober did complete. Its component '90linux-distro' took that long.
I understand that fedora too had slow os-prober - which seems to have been fixed around 2020. I don't know if any such fix made it into debian.

Aside, I had only used graphical installer so far, so thanks to both you and madza for helping with rescue mode et al.
_/\_

mrmazda
Posts: 500
Joined: 2023-06-02 02:22
Has thanked: 14 times
Been thanked: 63 times

Re: [Solved] GRUB os-prober seems to hang during install

#15 Post by mrmazda »

Nice to hear the virtue of patience paid off once again. :)

Post Reply