Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 790434 - sys-boot/os-prober-1.78 - fails to detect other Linux partitions
Summary: sys-boot/os-prober-1.78 - fails to detect other Linux partitions
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Peter Levine
URL:
Whiteboard:
Keywords: PullRequest, REGRESSION
Depends on:
Blocks:
 
Reported: 2021-05-15 22:41 UTC by ernsteiswuerfel
Modified: 2021-10-08 11:12 UTC (History)
3 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
grub.cfg generated with os-prober 1.78 (grub.cfg_bad,5.60 KB, text/plain)
2021-05-15 22:41 UTC, ernsteiswuerfel
Details
grub.cfg generated with os-prober 1.77 (grub.cfg_good,15.09 KB, text/plain)
2021-05-15 22:41 UTC, ernsteiswuerfel
Details
/etc/default/grub (grub,2.58 KB, text/plain)
2021-05-15 22:42 UTC, ernsteiswuerfel
Details
os-prober-1.77-debug (os-prober-1.77-debug.txt,150.41 KB, text/plain)
2021-05-16 22:17 UTC, ernsteiswuerfel
Details
os-prober-1.78-debug (os-prober-1.78-debug.txt,141.15 KB, text/plain)
2021-05-16 22:18 UTC, ernsteiswuerfel
Details
os-prober-1.78-btrfsfix.patch (os-prober-1.78-btrfsfix.patch,14.80 KB, patch)
2021-10-07 03:40 UTC, Peter Levine
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description ernsteiswuerfel archtester 2021-05-15 22:41:06 UTC
Created attachment 708852 [details]
grub.cfg generated with os-prober 1.78

grub-2.06_rc1 fails to detect other Linux partitions with os-prober-1.78 (Windows and UEFI partitions are detected though). With os-prober-1.77 grub detects everything correctly.

Happens on multiple machines of mine. GRUB_DISABLE_OS_PROBER="false" is set.
Comment 1 ernsteiswuerfel archtester 2021-05-15 22:41:31 UTC
Created attachment 708855 [details]
grub.cfg generated with os-prober 1.77
Comment 2 ernsteiswuerfel archtester 2021-05-15 22:42:24 UTC
Created attachment 708858 [details]
/etc/default/grub
Comment 3 Peter Levine 2021-05-16 05:39:37 UTC
If you're willing to help debug it and if your primary shell is bash, I'd ask you to run the following lines as root, without the initial "> " :

> emerge -1n app-portage/gentoolkit =sys-boot/os-prober-1.77::gentoo
> equery f  -f obj sys-boot/os-prober | grep -e '/usr/\(bin\|lib\)/' | xargs sed "/^\#\!\\/bin\\/sh/a export PS4=\'+(\${BASH_SOURCE}:\${LINENO}): \${FUNCNAME[0]:+\${FUNCNAME[0]}(): }\'\\nset -x" -i
> grub-mkconfig 2> /tmp/os-prober-1.77-debug.txt > /dev/null
> emerge -1n =sys-boot/os-prober-1.78::gentoo
> equery f  -f obj sys-boot/os-prober | grep -e '/usr/\(bin\|lib\)/' | xargs sed "/^\#\!\\/bin\\/sh/a export PS4=\'+(\${BASH_SOURCE}:\${LINENO}): \${FUNCNAME[0]:+\${FUNCNAME[0]}(): }\'\\nset -x" -i
> grub-mkconfig 2> /tmp/os-prober-1.78-debug.txt > /dev/null
> emerge -1 --selective=n sys-boot/os-prober
Then upload both /tmp/os-prober-1.77-debug.txt and /tmp/os-prober-1.78-debug.txt
Comment 4 ernsteiswuerfel archtester 2021-05-16 22:16:35 UTC
(In reply to Peter Levine from comment #3)
> [...]
> Then upload both /tmp/os-prober-1.77-debug.txt and
> /tmp/os-prober-1.78-debug.txt
Sure!
Comment 5 ernsteiswuerfel archtester 2021-05-16 22:17:36 UTC
Created attachment 709224 [details]
os-prober-1.77-debug
Comment 6 ernsteiswuerfel archtester 2021-05-16 22:18:01 UTC
Created attachment 709227 [details]
os-prober-1.78-debug
Comment 7 Peter Levine 2021-10-06 22:02:44 UTC
Sorry I didn't respond sooner.  I'll have some time in the next few days to examine the debug output.
Comment 8 Peter Levine 2021-10-07 03:40:58 UTC
Created attachment 743574 [details, diff]
os-prober-1.78-btrfsfix.patch

Try replacing /var/db/repos/gentoo/sys-boot/os-prober/files/os-prober-1.78-btrfsfix.patch with this one, re-emerge, and see if you can reproduce the issue.
Comment 9 ernsteiswuerfel archtester 2021-10-07 22:44:46 UTC
(In reply to Peter Levine from comment #8)
> Try replacing
> /var/db/repos/gentoo/sys-boot/os-prober/files/os-prober-1.78-btrfsfix.patch
> with this one, re-emerge, and see if you can reproduce the issue.
Many thanks! I can confirm the patch fixes the issue.
Comment 10 Larry the Git Cow gentoo-dev 2021-10-08 11:12:32 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=733c692eca0ad50591ccf11cfcf89e317291f35f

commit 733c692eca0ad50591ccf11cfcf89e317291f35f
Author:     Peter Levine <plevine457@gmail.com>
AuthorDate: 2021-10-08 01:13:01 +0000
Commit:     Ben Kohler <bkohler@gentoo.org>
CommitDate: 2021-10-08 11:12:16 +0000

    sys-boot/os-prober: replace os-prober-1.78-btrfsfix.patch
    
    Replace os-prober-1.78-btrfsfix.patch with changes from OpenSUSE's
    os-prober-btrfs-always-detect-default.patch to fix OS detection issues.
    
    Closes: https://bugs.gentoo.org/790434
    Package-Manager: Portage-3.0.26, Repoman-3.0.3
    Signed-off-by: Peter Levine <plevine457@gmail.com>
    Signed-off-by: Ben Kohler <bkohler@gentoo.org>

 .../os-prober-1.79-btrfs-subvolume-detection.patch | 505 +++++++++++++++++++++
 sys-boot/os-prober/os-prober-9999.ebuild           |   2 +-
 2 files changed, 506 insertions(+), 1 deletion(-)