openSuSE / OSX Dual Boot on iMac G6 (Intel) - weird grub error

Hi all,

i tried to set up a Dual Boot with openSuSE 12.1 and Mac OS X 10.6.8 on my iMac G6 - i followed exactly this documentation: OpenSUSE on a Mac - openSUSE

in details:
1. Used the OS X Partition Tool to divide my 500 Gig HDD into 2 equal Partitions but formatted the second one with DOS filesystem.
2. Installed rEFIt and wrote it to the MBR - afterwards i tried several reboots - worked perfect for me.
3. Booted openSuSE netinstall .iso from usb dongle, deleted the second DOS Partition and created a new root “/” partition with ext4 filesystem
Installation ran through without any errors - afterwards the reboot resulted into a blackscreen, everything was frozen and only a hard reset helped.
I checked that i DON’T install grub into the MBR like 5 times - the installation menu showed me that GRUB would be installed to “/” root partition /dev/sda3 which is complete correct in my case. I also read in an description that it’s important to uncheck something like “installing generic grub to MBR” - i found that checkbox after searching a bit and unchecked it of cause.
4. Then i saw the rEFIt menu again, now with 2 icons (one for Mac OS, another one with tux logo on it) → choosing tux resulted into a grub error 21 or 22 (i found out that the 22 error happens when i call the rEFIt partition tool in ne rEFIt menu before, otherwise its 21).
5. I’m wondering: grub freezes immediately when i try to change to grub console … letting me no chance of checking if the paths are set correctly
6. Then i tried to boot the iso from the usb dongle again to call something like a “repair-routine”, but it always tries to start the linux partition from the hard disk.

Maybe after the Installation routine, openSuSE switches back to the installation menu to do some final work… i have this in my mind from earlier (standard) SuSE installations on different boxes… and this fails because rEFIt interrupts that?

sudo gptsync /dev/disk0 in OS X returns:

Current GPT partition table:

Start LBA End LBA Type

1 40 409639 EFI System (FAT)
2 409640 488460335 Mac OS X HFS+
3 488462336 976773119 EFI System (FAT)

Current MBR partition table:

A Start LBA End LBA Type

1 1 409639 ee EFI Protective
2 409640 488460335 af Mac OS X HFS+
3 * 488462336 976773119 83 Linux

Status: MBR table must be updated.

Proposed new MBR partition table:

A Start LBA End LBA Type

1 1 409639 ee EFI Protective
2 409640 488460335 af Mac OS X HFS+
3 488462336 976773119 83 Linux
4 976773120 976773167 ee EFI Protective

Any advices?
Anyone with an idea?

Best regards!

That’s obviously wrong. Why would you have 2 EFI partitions?
This is how the protective MBR looks like under OS X Lion:

WARNING: GPT (GUID Partition Table) detected on '/dev/sda'! The util fdisk doesn't support GPT. Use GNU Parted.


Disk /dev/sda: 250.1 GB, 250059350016 bytes
255 heads, 63 sectors/track, 30401 cylinders, total 488397168 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x00002652

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1               1      409639      204819+  ee  GPT
/dev/sda2          409640   351461631   175525996   af  HFS / HFS+
/dev/sda3       351461632   352731175      634772   ab  Darwin boot
/dev/sda4   *   352731176   488134983    67701904   83  Linux

Under Leopard and Snow Leopard, there is no “Darwin boot” partition and the Linux partition is the third one.

I never run “repair routines” and I doubt they will do the right thing on Mac EFI hardware.

One more thing. Although rEFIt is still an option (I used it myself), it was never required for Linux, and you could perform a true EFI installation and boot both OS X and Linux with grub2-efi (not grub!). It’s a totally different method that I haven’t tried yet on Mac hardware, but it’s probably a better approach. rEFIT should work though. It does for me.