Ubuntu

[grub2] fails to start OS X

Reported by Christian Stöveken on 2009-06-16
42
This bug affects 7 people
Affects Status Importance Assigned to Milestone
grub2 (Ubuntu)
Undecided
Unassigned

Bug Description

Binary package hint: grub2

The computer is a MSI Wind U100 which has
- Windows XP
- Windows 7
- Ubuntu 9.04
- OS X 10.5.5
installed.

Issues:
- root/uuid problem:
https://bugs.launchpad.net/bugs/376879
- the timeout is now different:
https://bugs.launchpad.net/bugs/376879
- the last booted system doesn't get saved anymore (like with savedefault):
https://bugs.launchpad.net/ubuntu/+source/grub2/+bug/216178
- OS X doesn't get detected

ProblemType: Bug
Architecture: i386
DistroRelease: Ubuntu 9.04
Package: grub2 1.96+20080724-12ubuntu2
ProcEnviron:
 LANG=de_DE.UTF-8
 SHELL=/bin/bash
SourcePackage: grub2
Tags: ubuntu-unr
Uname: Linux 2.6.28-11-generic i686

On Tue, Jun 16, 2009 at 09:02:45PM -0000, Christian Stöveken wrote:
> Issues:
> - root/uuid problem:
> https://bugs.launchpad.net/bugs/376879
> - the timeout is now different:
> https://bugs.launchpad.net/bugs/376879
> - the last booted system doesn't get saved anymore (like with savedefault):
> https://bugs.launchpad.net/ubuntu/+source/grub2/+bug/216178

Acknowledged, but (a) it's best for bugs to refer to one issue and one
issue only in order for them to be tractable by developers, (b) if all
those bugs have been filed already there's really no need to file
another bug about them. We're definitely aware of all these problems.

> - OS X doesn't get detected

This is a new one, though (at least as far as I'm aware). Can we narrow
the scope of this bug to be about just this problem, please?

It's probably an os-prober problem. Could you tell me, please:

 * which filesystem type is being used for OS X?
 * does the file 'mach_kernel' exist in the root directory of the OS X
   filesystem?

Thanks in advance.

 status incomplete

Changed in grub2 (Ubuntu):
status: New → Incomplete

> Acknowledged, but (a) it's best for bugs to refer to one issue and one
> issue only in order for them to be tractable by developers, (b) if all
> those bugs have been filed already there's really no need to file
> another bug about them. We're definitely aware of all these problems.
Agreed.

> > - OS X doesn't get detected
> This is a new one, though (at least as far as I'm aware). Can we narrow
> the scope of this bug to be about just this problem, please?

> It's probably an os-prober problem. Could you tell me, please:

> * which filesystem type is being used for OS X?
hfs+ (needs hfsprogs to mount I suppose)
> * does the file 'mach_kernel' exist in the root directory of the OS X filesystem?
yes, it does

> Thanks in advance.
Well, thank you and I'll of course provide you with further info as fast as possible.

On Wed, Jun 17, 2009 at 12:07:39AM -0000, Christian Stöveken wrote:
> > * which filesystem type is being used for OS X?
> hfs+ (needs hfsprogs to mount I suppose)

You need hfsprogs to create or check HFS+ filesystems, but not to mount
them.

> > * does the file 'mach_kernel' exist in the root directory of the OS X filesystem?
> yes, it does

OK, that's pretty odd then since this should work. Would you mind
attaching /var/log/syslog to this bug, which should contain some
debugging output from os-prober? If it contains anything sensitive, you
can mail it to me privately if that would be preferable. TIA.

Colin Watson (cjwatson) wrote :

On Wed, Jun 17, 2009 at 02:03:23AM +0100, Colin Watson wrote:
> OK, that's pretty odd then since this should work. Would you mind
> attaching /var/log/syslog to this bug, which should contain some
> debugging output from os-prober? If it contains anything sensitive, you
> can mail it to me privately if that would be preferable. TIA.

Er, I'm assuming that you've run update-grub recently, either by hand or
by way of an upgrade. If not then you could always run it again to get
debugging output.

> - Ubuntu 9.04

Jaunty's /etc/grub.d/30_os-prober doestn't support MacOS X only the karmic version does.
AFAICS os-prober doestn't return :chain with MacOS X (which would be strange anyway), so IMO this bug is invalid.
The karmic version should add it fine.

On Wed, Jun 17, 2009 at 07:22:12AM -0000, Felix Zielcke wrote:
> > - Ubuntu 9.04
>
> Jaunty's /etc/grub.d/30_os-prober doestn't support MacOS X only the karmic version does.

Oh, right! Thanks for that, I was clearly going down the wrong path with
my diagnosis. The syslog Christian sent me confirms that os-prober
itself is indeed detecting OS X properly, so /etc/grub.d/30_os-prober is
the only remaining piece.

> AFAICS os-prober doestn't return :chain with MacOS X (which would be
> strange anyway),

Indeed, it returns :macosx.

 status fixreleased

summary: - grub2 doesn't detect all installed operating systems correctly and other
- issues
+ fails to detect OS X
Changed in grub2 (Ubuntu):
status: Incomplete → Fix Released

After upgrading to Karmic an entry for OS X shows up - but OS X now boots to a frozen blueish screen.
Also the OS X bootsplash isn't working.

Changed in grub2 (Ubuntu):
status: Fix Released → New
summary: - fails to detect OS X
+ [Karmic, grub2] fails to start OS X

I'm running a 13" Macbook Pro and grub2 is also not booting OS X even though it's making a menu entry for it in grub.cfg.

My grub.cfg:

### BEGIN /etc/grub.d/30_os-prober ###
menuentry "Mac OS X (on /dev/sda2)" {
 insmod hfsplus
 set root=(hd0,2)
 search --no-floppy --fs-uuid --set 80ca433c88483ea9
        insmod vbe
        do_resume=0
        if [ /var/vm/sleepimage -nt10 / ]; then
           if xnu_resume /var/vm/sleepimage; then
             do_resume=1
           fi
        fi
        if [ $do_resume == 0 ]; then
           xnu_uuid 80ca433c88483ea9 uuid
           if [ -f /Extra/DSDT.aml ]; then
              acpi -e /Extra/DSDT.aml
           fi
           xnu_kernel /mach_kernel boot-uuid=${uuid} rd=*uuid
           if [ /System/Library/Extensions.mkext -nt /System/Library/Extensions ]; then
              xnu_mkext /System/Library/Extensions.mkext
           else
              xnu_kextdir /System/Library/Extensions
           fi
           if [ -f /Extra/Extensions.mkext ]; then
              xnu_mkext /Extra/Extensions.mkext
           fi
           if [ -d /Extra/Extensions ]; then
              xnu_kextdir /Extra/Extensions
           fi
           if [ -f /Extra/devtree.txt ]; then
              xnu_devtree /Extra/devtree.txt
           fi
           if [ -f /Extra/splash.jpg ]; then
              insmod jpeg
              xnu_splash /Extra/splash.jpg
           fi
           if [ -f /Extra/splash.png ]; then
              insmod png
              xnu_splash /Extra/splash.png
           fi
           if [ -f /Extra/splash.tga ]; then
              insmod tga
              xnu_splash /Extra/splash.tga
           fi
        fi
}
### END /etc/grub.d/30_os-prober ###

LasVegas (lasvegas) wrote :

I've just filed a similar bug report before I found this report. The problem I reported was that (for me) the part_gpt module needs to be loaded for grub to find the OSX partition. So one possible solution is that grub.cfg should list:

insmod hfsplus
insmod part_gpt
set root=(hd0,2)

the part_gpt module for GPT partitioning, should then give grub2 access to the (hd0,2) partition.

(The hanging blue screen may be because the dsdt.aml acpi/bios file was not properly loaded ... on my machine without the dsdt.aml file properly loading OSX will hang for quite a while at the blue screen, but will eventually load. It seems to be an OSX/SATA issue on my machine.)

Francisco Villalobos (belhor) wrote :

GRUB2 starts Leopard in verbose mode, but at final the boot freezes

Francisco Villalobos (belhor) wrote :

I installed Ubuntu 10.04 LTS and still haven the same problem with GRUB 2

gabr10 (gabriobarbieri) wrote :

Same here, installed 10.04 LTS and GRUB2 creates two menu entries for OSX, it boots in verbose and safe mode so obviously something's wrong.

Under 10.10 I get two menu entries for Mac OS X:

menuentry "Mac OS X (32-bit) (on /dev/sda2)"

and

menuentry "Mac OS X (64-bit) (on /dev/sda2)"

Are the people having this bug on currently supported releases (10.04 onwards) using Apple hardware or otherwise? Personally I'm not even using the Ubuntu grub package - I'm using rEFIt and a self-compiled grub2 that I copied into the EFI partition.

Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in grub2 (Ubuntu):
status: New → Confirmed
Xiaojun Ma (damage3025) on 2012-11-04
summary: - [Karmic, grub2] fails to start OS X
+ [grub2] fails to start OS X
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Duplicates of this bug

Other bug subscribers