Bug#533898: grub-common: "grub-probe --device /dev/hda4 --target=drive" returns (hd0, 4), should return (hd0, 3)

Colin Watson cjwatson at debian.org
Mon Jul 12 15:53:31 UTC 2010


On Mon, Jul 12, 2010 at 05:35:54PM +0200, Lutz Lehmann wrote:
> Package: grub-common
> Version: 1.97~beta3-1~bpo50+1
> Followup-For: Bug #533898
> 
> Hello,
> 
> see subject. Perhaps too trivial, but in the opening post the
> grub-probe command should return (hd0,3) instead of (hd0,4). Grub
> counts from 0, the dev system from 1, so /dev/hda1 translates to
> (hd0,0) etc.

No, GRUB 2 counts from 1, not 0.  GRUB Legacy counted from 0, but the
GRUB Legacy packaging in Debian sets the environment variable
GRUB_LEGACY_0_BASED_PARTITIONS=1 when calling grub-probe, and this
causes it to count from 0.

-- 
Colin Watson                                       [cjwatson at debian.org]





More information about the Pkg-grub-devel mailing list