This post is intended only for actual Apple (Mac) computer systems that are not booting due to accidental installation of the chameleon bootloader to the Apple computer system’s hard drive.
If you are one of the unlucky ones who ignored my numerous warnings or just accidentally pressed the wrong button while running the myHack installer from a real MAC here is an example of how to repair the partition scheme on a real MAC so that it will boot again – after accidentally installing the chameleon bootloader to the MAC’s internal hdd.
Note: I have not tested this myself – I’m not that adventurous when it comes to my real MAC, however these commands should work. Ultimately if nothing posted here works you will likely have to wipe the drive out completely and re-install OS X.
WARNING: Do not perform any of the following actions without backing up your critical data first. Fiddling with partition tables is dangerous. A simple typo could lead to complete data loss. You have been warned! [ You can backup critical data even if you can not access the system, if absolutely necessary, by removing the internal hdd and plugging it into another computer, the use of data recovery software may be required depending on circumstances. ]
1) Boot your mac with an OS X Install DVD (doesn’t matter which version, whatever is installed on your system would be best).
2) Start Disk Utility
3) Select the OS X HDD/SSD that you screwed up (not specific partition)
4) Go to the Partition tab
5) Grab the lower right corner of your key partition and resize it a little bit (no matter how much/little you resize it as long as you change the partition size)
6) Click Apply. Relax, this will NOT erase your HDD/SSD, it only rewrites your GUID partition data that will fix your HDD/SSD.
7) Quit the Disk Utility and reboot.
8) Enjoy your restored Mac that should now boot normally!
Boot your mac with an OS X Install DVD (doesn’t matter which version, whatever is installed on your system would be best) and use Terminal on it to run the following commands.
Once booted into the GUI, open a terminal and type
to get a list of all disks on your system. Assuming /dev/disk2 is your problematic disk with the MBR partition scheme, type
sudo fdisk /dev/disk2
to verify the current partitions on it (should list partitions on the disk, if not don’t worry it’s likely because of the chameleon bootloader). This command will not apply any changes. The drive with an “*” next to it is the active partition (if any). Now type
sudo fdisk -u /dev/disk2
which writes a new MBR (master boot record) while keeping current partition information.
In order to be able to boot from a partition, it must be flagged active. Type
sudo fdisk -e /dev/disk2
to open the drive in fdisk’s editing mode. It will possibly complain “could not open MBR file /usr/standalone/i386/boot0: No such file or directory”, this should be safe to ignore. The following transcript shows what to do next:
fdisk: 1> flag 2
Partition 2 marked active.
Writing current MBR to disk.
You’re done! Cross your fingers and reboot your MAC…
If any of this is confusing to you please read the OS X fdisk man page for more information.