Bug#534644: os-prober: ignores separate boot partition when mounted

2012-11-27 Thread Claudio Moretti
Package: os-prober
Version: 1.56
Followup-For: Bug #534644


I had this problem for a while: os-prober does not recognize Windows
(any version) when the Windows partition is mounted. And this is really
annoying for someone who wants to share their files between two
different OSes.

I hope I am not wrong, but I think that this bug severity should be
raised to important, because anyone who needs os-prober
(regardless of the fact that it comes by default with GRUB) because they
have a dual boot system is likely to mount the other partition at some
point.
In that moment, if grub-update is launched (or triggered by APT - which
is more likely), the OS in the mounted partition will disappear from the
boot list (at least until update-grub is launched/triggered again with
the OS partition not mounted.).

I was able to reproduce this bug by launching os-prober from root with
the mounted partitions, obtaining no output. After manually unmounting
the partitions, os-prober returns the correct list. 

Then, I have mounted the partitions again (see below) and re-launched
os-prober:

claudio@Chuck:~$ sudo os-prober 
[sudo] password for claudio: 
/dev/sda1:Windows 8 (loader):Windows:chain
claudio@Chuck:~$ sudo mount -a
claudio@Chuck:~$ sudo os-prober 
claudio@Chuck:~$ 

-- System Information:
Debian Release: wheezy/sid
  APT prefers unstable
  APT policy: (1001, 'unstable'), (600, 'experimental')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 3.2.0-4-amd64 (SMP w/8 CPU cores)
Locale: LANG=en_US.utf8, LC_CTYPE=en_US.utf8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages os-prober depends on:
ii  libc6  2.13-37

os-prober recommends no packages.

os-prober suggests no packages.

-- no debconf information


-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of unsubscribe. Trouble? Contact listmas...@lists.debian.org



Bug#534644: os-prober: ignores separate boot partition when mounted

2009-06-25 Thread Kevin Mitchell
Package: os-prober
Version: 1.29
Severity: normal

I have a second install of Debian Lenny on an other partion. It boots off yet 
an other partition. 
It's relevant /etc/fstab entries are

/dev/sda2 /boot   ext3defaults,noatime   0  0
/dev/sda6 /  autodefaults,noatime   0  0

On my running sid, I have these partitions mounted
/dev/sda2 /mnt/sandbox/boot
/dev/sda6 /mnt/sandbox

The relevant menu entry in /mnt/sandbox/boot/grub/grub.cfg (i.e., residing on 
/dev/sda2) is


menuentry Debian GNU/Linux, linux 2.6.30.012 {
set root=(hd0,2)
search --fs-uuid --set 234cc6d9-e0ef-4105-b817-f1c83edbc1a2
linux   /vmlinuz-2.6.30.012 root=/dev/sda5 ro i915.modeset=1 selinux=0 
enforcing=0 resume=/dev/sda3  clocksource=hpet quiet
}

When I run 

linux-boot-prober /dev/sda6

on standard output I see

/dev/sda6:/dev/sda6::/boot/vmlinuz-2.6.26-2-amd64:/boot/initrd.img-2.6.26-2-amd64:root=/dev/sda6

and in /var/log/syslog
 
linux-boot-prober: debug: /usr/lib/linux-boot-probes/mounted/90fallback 
succeeded

However I expect to see

/dev/sda6:/dev/sda2:Debian GNU/Linux, linux 
2.6.30.012:/boot/vmlinuz-2.6.30.012::root=/dev/sda5 ro i915.modeset=1 selinux=0 
enforcing=0 resume=/dev/sda3 clocksource=hpet quiet

Which I do see with the attached patch applied to /usr/bin/linux-boot-prober.

Kevin

-- System Information:
Debian Release: squeeze/sid
  APT prefers unstable
  APT policy: (600, 'unstable'), (500, 'testing'), (400, 'stable'), (300, 
'experimental')
Architecture: amd64 (x86_64)

Kernel: Linux 2.6.30.012 (SMP w/2 CPU cores; PREEMPT)
Locale: LANG=en_GB, LC_CTYPE=en_GB (charmap=ISO-8859-1)
Shell: /bin/sh linked to /bin/dash

-- no debconf information
--- /usr/bin/linux-boot-prober  2008-12-26 05:48:07.0 -0800
+++ /usr/local/bin/linux-boot-prober2009-06-25 16:33:12.105222571 -0700
@@ -32,7 +32,7 @@
bootpart=${mountboot%% *}
bootmounted=${mountboot#* }
else
-   bootpart=$partition
+   bootpart=$(cat $mpoint/etc/fstab | parsefstab | grep  
/boot  | cut -d' ' -f1)
bootmounted=0
fi
for test in /usr/lib/linux-boot-probes/mounted/*; do