[Bug 785341] New: grub2 generates wrong logical partition numbers
https://bugzilla.novell.com/show_bug.cgi?id=785341 https://bugzilla.novell.com/show_bug.cgi?id=785341#c0 Summary: grub2 generates wrong logical partition numbers Classification: openSUSE Product: openSUSE 12.2 Version: Final Platform: Other OS/Version: openSUSE 12.2 Status: NEW Severity: Normal Priority: P5 - None Component: Bootloader AssignedTo: jsrain@suse.com ReportedBy: arvidjaar@gmail.com QAContact: jsrain@suse.com Found By: --- Blocker: --- User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:15.0) Gecko/20100101 Firefox/15.0.1 This was pointed out by user of forums: # grub2-probe --target=device /boot /dev/sda9 # grub2-probe --target=drive /boot (hd0,msdos13) Ubuntu 12.04 gets it right. The bug is, in case of logical partitions grub2 counts also "glue" partition entries that point to next EMBR (next logical partition MBR). Upstream already has fix for it. I guess as long as grub2 makes it consistently everywhere it is OK, so it is not MAJOR. But it is highly confusing for all users, so consider for 12.2 update. Here is minimal patch: --- grub-core/partmap/msdos.c 2012-10-03 23:03:35.000000000 +0400 +++ /home/bor/src/grub/grub-core/partmap/msdos.c 2012-09-19 19:48:29.000000000 +0400 @@ -181,15 +181,11 @@ grub_partition_msdos_iterate (grub_disk_ (unsigned long long) p.len); /* If this partition is a normal one, call the hook. */ - if (! grub_msdos_partition_is_empty (e->type)) + if (! grub_msdos_partition_is_empty (e->type) + && ! grub_msdos_partition_is_extended (e->type)) { p.number++; - /* prevent someone doing mkfs or mkswap on an - extended partition, but leave room for LILO */ - if (grub_msdos_partition_is_extended (e->type)) - p.len = 2; - if (hook (disk, &p)) return grub_errno; } Reproducible: Always Steps to Reproduce: 1. 2. 3. -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=785341
https://bugzilla.novell.com/show_bug.cgi?id=785341#c1
Agnelo de la Crotche
https://bugzilla.novell.com/show_bug.cgi?id=785341
https://bugzilla.novell.com/show_bug.cgi?id=785341#c2
--- Comment #2 from Andrey Borzenkov
https://bugzilla.novell.com/show_bug.cgi?id=785341
https://bugzilla.novell.com/show_bug.cgi?id=785341#c3
--- Comment #3 from Andrey Borzenkov
https://bugzilla.novell.com/show_bug.cgi?id=785341
https://bugzilla.novell.com/show_bug.cgi?id=785341#c4
--- Comment #4 from Michael Chang
https://bugzilla.novell.com/show_bug.cgi?id=785341
https://bugzilla.novell.com/show_bug.cgi?id=785341#c5
--- Comment #5 from Michael Chang
https://bugzilla.novell.com/show_bug.cgi?id=785341
https://bugzilla.novell.com/show_bug.cgi?id=785341#c6
--- Comment #6 from Michael Chang
https://bugzilla.novell.com/show_bug.cgi?id=785341
https://bugzilla.novell.com/show_bug.cgi?id=785341#c
Jiri Srain
https://bugzilla.novell.com/show_bug.cgi?id=785341
https://bugzilla.novell.com/show_bug.cgi?id=785341#c7
--- Comment #7 from Andrey Borzenkov
Andrey,
Could you please submit the refreshed patch to factory? And I think 12.2 maintenance update is necessary.
Factory: 138745 12.2: 138746 -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=785341
https://bugzilla.novell.com/show_bug.cgi?id=785341#c8
Michael Chang
Factory: 138745
Accepted. Thanks a lot.
12.2: 138746
Dear Maintenance Team: Could you please help to process the maintenance request. Thanks. Michael -- Configure bugmail: https://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are on the CC list for the bug.
https://bugzilla.novell.com/show_bug.cgi?id=785341
https://bugzilla.novell.com/show_bug.cgi?id=785341#c9
Benjamin Brunner
https://bugzilla.novell.com/show_bug.cgi?id=785341
https://bugzilla.novell.com/show_bug.cgi?id=785341#c10
Benjamin Brunner
https://bugzilla.novell.com/show_bug.cgi?id=785341
https://bugzilla.novell.com/show_bug.cgi?id=785341#c11
--- Comment #11 from Swamp Workflow Management
participants (1)
-
bugzilla_noreply@novell.com