InfiniteMac OSx86

InfiniteMac OSx86 (http://infinitemac.com/forum.php)
-   10.X (http://infinitemac.com/forumdisplay.php?f=36)
-   -   How to create & customize a Retail Installer on a USB Drive with Chameleon 2 RC1 (http://infinitemac.com/showthread.php?t=2789)

thorazine74 05-07-2009 05:15 PM

How to create & customize a Retail Installer on a USB Drive with Chameleon 2 RC1
 
1 Attachment(s)
This pretends to be a simple guide with pictures to install Leopard Retail from a USB drive to a hard disk using Chameleon 2 RC1.
[Updated 15/05/2009]: It involves using Chameleon2 RC1 to boot a copy of a Retail DVD on a USB Drive, install from there to a hard disk partition, boot the newly installed partition from the same USB Drive, and perform the necesary kext/kernel/chameleon installation over the HD partition to make it able to boot from it independently (it could also be posible to keep the USB Drive as the boot device and dont touch the partition with the retail installation at all but I havent tested this scenery).
It is assumed you know what kexts your specific hardware needs to boot and work as you would need to provide them for the USB drive to boot, this is meant to be a general guide, not specific for any hardware. Its supposed to be a replacement for boot132 methods where you dont have a ready made dvd and need to create one, with this method you can easily customize the kexts used during installation just by copying them to the USB drive instead of creating custom isolinux images. Also it can be useful when you have troubles with distros that doesnt support a specific SATA/IDE Controller and, instead of modding the distro DVD to inject the missing kexts, it would be easier to mod the retail with the storage controller's kexts you need to boot.
It has been tested on a GA-73PVM-S2H board (nForce 630i/Geforce 7100 chipset, C2D E8200, Geforce 8600 GTS), installing from a generic SanDisk USB Stick to a SATA AHCI hard disk partition in MBR format, using the vanilla kernel.
This is my first time installing retail so please correct any mistakes or stupidities I may have done but this worked for me at first try so I'm sharing it to help other people install retail.

REQUIREMENTS:

Hardware:
A 8 Gb USB Drive (smaller will do if you remove some installation packages)
Being able to boot from USB (most motherboards will, need to configure BIOS to select device boot order)
Software:
Chameleon 2.0 RC1 Installer
Leopard Retail DVD/DMG (tested with Leopard 10.5.6 - 9566 Build)
An existing installation of Leopard (doesnt need to be the same computer)
STEP 1: COPYING THE INSTALLATION DVD/DMG

You need to repartition the USB drive and dump the retail installation media to the DVD drive using Disk Utility.

A) Erase the USB Drive:

Plug in the USB Drive.
Open Disk Utility and select the USB Drive in the left:

http://img512.imageshack.us/img512/5...lacapture3.png
Click on the Partition tab and select Volume Scheme: 1 partition:

http://img407.imageshack.us/img407/1...lacapture4.png
Click on the Options button and make sure the Master Boot Record option is selected:


http://img527.imageshack.us/img527/4...lacapture6.png

It should be the default but its mandatory for the USB drive to boot so better to be sure.
The Volume Format should be Mac OS Extended Journaled but its selected by default.
You can name it something like "Mac OS X Install USB" to avoid mistaking it.
Click on the Apply button and wait while the whole USB drive is repartitioned into a single MBR partition with HFS+ format.

B) Copy install media to the new USB partion:

Insert Mac OS X Retail DVD disk or mount the corresponding DMG image or just drag it to Disk Utility.
Select the USB Drive on the left and click on the Restore tab.
You have to select the Mac OS X Install DVD as the source and the Mac OS X Install USB as the Destination, dragging them from the list of units on the left to the corresponding field on the right (or by selecting each of them as Source or Destination in their respective context menu).

http://img527.imageshack.us/img527/8...lacapture7.png
Select the Erase destination option and click Restore.
This will take a while as it will copy the whole DVD to the USB.

STEP 2: EDIT THE OSINSTALL.MPKG TO ALLOW INSTALLATIONS ON A MBR PARTITION

[Updated 15/05/2009]: By default the Retail DVD doesnt let you install over a partition in an MBR partitioned disk, when you select the partition to install it just gives you the choice to Erase the disk into a GPT partitioned format.
If you already have a GPT partitioned disk or you dont mind repartitioning that way with Disk Utility you dont need to do anything and can use the Retail Install as it is.
But if you need to install into an already existing MBR partition and you dont want to erase the whole disk or you just simply dont want to use GPT, you need to edit a file in the retail dvd to allow that.
Basically you have to extract the contents of the OSInstall.mpkg file with a XAR compressor command, edit the (text file) named Distribution contained inside changing directive that says eraseOptionAvailable='true' into eraseOptionAvailable='false'.
And compress all the files you extracted back into a new OSInstall.mpkg using XAR again.
You can follow the specific steps detailed in this thread (part b)
Instead of compiling XAR compressor by yourself you also can get a binary from this page. Keep in mind that there is already a xar command in Mac OS X but its not v1.5.2, make sure you are using the right version you have installed (find them all with "which -a xar" and find the version of each with "/full/path/xar --version" and use the full path to the right version when performing the decompression and compression).
Here its an already edited OSInstall.mpkg taken from Mac OS X Retail 10.5.6 (9G66), it may work with other versions too but its not tested.

You just have to replace the OSInstall.mpkg in the USB Drive located in with the new one edited. Keep a backup copy of the original just in case.
(remember you need to be able see hidden files in the finder to do that).


http://img36.imageshack.us/img36/3510/voilacapture.png

STEP 3: MAKE THE USB DRIVE BOOTABLE

Right now you have Leopard Installer on the USB but you are not able to boot from it yet.
What you need is simply to install Chameleon Boot Loader onto it to make it bootable.
For this just launch Chameleon official installer and follow the prompts until you reach the page where you can Choose Install Location. Click that button and make sure you select the same USB drive you want to boot from on the list:

http://img208.imageshack.us/img208/9...acapture10.png

STEP 4: CUSTOMIZE CHAMELEON CONFIG ON THE USB

The USB Drive is already bootable but you need to configure certain things to be able to boot the Install DVD succesfully.

A) Kexts:
You need to add all the kexts you need to the Extra\Extensions\ folder on the USB Drive.
1. Mininum (always required) ones:
- AppleDecrypt.kext or dsmos.kext
- IntelCPUPMDisabler.kext or a generic Disabler.kext to avoid AppleIntelCPUPowerManagement.kext crashes.
- You should need no SMBIOS enabler because I think Chameleon 2 already does that.
2. PS/2 Keyboard and Mouse/Trackpad support:
Either VoodooPS2Controller.kext or APCIPS2Nub.kext+ApplePS2Controller.kext (just one of them), of course not needed if you use USB Mouse & Keyboard).
3. Storage Controller support:
This will vary depending on what board you are going to install, if its not natively supported by Vanilla Leopard you need to add its kexts. Keep in mind that you only need to see the destination disk in the installer, so if for instance you are installing to SATA, you dont need IDE support even if you have an IDE DVD because it will not be used during installation.
4. Other kexts you may need during installation:
I'm not sure if any graphics kexts are needed to boot the graphical installer, for my NVIDIA card its not needed, I dont know about ATI.
[Updated 21/05/2009]: Remember to modify kexts' info.plist OSBundleRequired property to Root if needed (VoodooPS2Controller.kext needs this, for instance). The "Root" value seems to be required for any kext to load successfully from /Extra/Extensions.
If you are not using legacy (plist-only) kexts but modded ones that overlap Apple's originals present in /System/Library/Extensions (for instance, a full modded AppleIntelPIIXATA.kext or IOATAFamily.kext with a binary instead of just LegacyApplePIIXATA.kext) I think you also need to increase the version properties in each info.plist so the ones in /Extra/Extensions get favored over the ones in /System/Library/Extensions on the loading queue.

B) Custom Kernel:
If your system can boot the vanilla kernel (AMD, i7), you also need to install the Voodoo kernel to the USB Drive.
I'm not using it at the moment but I think the mach_kernel.voodoo file has to be in the root of the USB drive.
You may also need to include the System.kext that comes with Voodoo Kernel (in Extra\Extensions\ folder), but I think its only needed for proper USB hotplug support (not needed for just USB detection).

C) com.apple.boot.plist customizations:
Follow Chameleon's help to configure it accordingly to your system (for instance you need to specify the voodoo kernel here if you want to use it).

D) smbios.plist customizations:
I think this is not needed for installation, at least for my system, but if you need to set specific SMBIOS values edit this file.

E) Custom DSDT:
You can also include a modded DSDT.aml file, I think it goes in Extra too but I havent tested (if you use one you should not even need to include a disabler kext for AppleIntelCPUPowerManagement). This is not tested by me either.

http://img410.imageshack.us/img410/9...acapture11.png

I think thats all, Chameleon its too new so if I've missed something please correct me.

STEP 5: BOOT AND INSTALL FROM THE USB DRIVE

With this you can restart the computer, configure your BIOS accordingly and boot from the USB drive.
You should see Chameleon menu and it should select the boot device by default.
Just press Enter or better press Arrow Down to make the Options menu appear and select the option to boot in verbose mode to see whats going on if something goes wrong.
You can also type kernel or booting parameters there if needed, just read the help.
The Mac OS X Installation should start, just follow the typical installation procedures from the other guides.
Remember that you wont be able to install into a MBR partition by default, you would need to mod the OSInstall.mpkg on the DVD for that. There are also guides for that in the forum.
If all goes well the installation will complete in about 10 minutes (depending on what options you choose) but it will complain at the end that it failed because it couldnt make the destination volume bootable.

STEP 6: FIX INSTALLATION VOLUME

You should have Mac OS X installed on the destination drive/partition but you are not able to boot from it on its own.
You can however boot from the same USB Drive you have used from installation and when prompted by the Chameleon Menu, select the destination partition where you installed Leopard instead of the Default "Mac OS X Install USB".
The new Leopard installation should boot to the desktop and when you are there you need to install Chameleon again but now on the Hard Disk partition and copy the extra extensions (and kernel) you have used on the USB drive the hard drive, same as you would do with boot132 installation methods.
[Updated 15/05/2009]: Keep in mind that if you are using voodoo or other kernel you may need to specify it in the chameleon's com.apple.Boot.plist configuration so the mach_kernel.voodoo file from the USB drives is used instead of the vanilla mach_kernel in the HD partition. You can also copy it to the destination partition before booting from replacing vanilla mach_kernel. I'm not using voodoo kernel so I cant give detailed instructions, pleaser refer to the Chameleon 2's threads for more help on how to specify a custom kernel when booting an HD partition from an USB Drive.

archimed 05-12-2009 07:40 AM

Hi Thorazine. Thanks so much for posting this guide.
I've got the same motherboard and USB key as you..
gigabyte ga-73pvm-s2h
sandisk cruzer 8gb
bfg 9800GT
SATA hd

I'm having trouble booting the installer. I followed your steps, but when I choose my Mac OS X install disc in Chameleon, it starts loading up a few kexts, says "Loading Darwin x86".. and goes into a reboot loop. I've spent hours trying to figure this out... BIOS settings, command line switches (-f -x -v -s cpus=1), and nothing is working for me so far.

I've even tried installing the voodoo kernel, but it gets to the install screen (so, it does get further), and the kernel panics.

Any advice? The reboot loop really sucks.

EDIT: I forgot to note - I was using Leopard retail 10.5.1 .. I'm trying 10.5.6 now. Will update this thread if there are any changes.

archimed 05-12-2009 11:01 PM

Update! The 10.5.6 Retail worked... no more boot looping. Now I just need to figure out how to get it to recognize my SATA drives.

Peanut Vendor 05-15-2009 09:33 AM

gigabyte ga-ex58-ud5 and evga gts 250 problems!
 
I have been having loads of problems getting my system to work; this will be my next method to try. My video card is an EVGA NVidia Geforce GTS 250. Motherboard is Gigabyte ga-ex58-ud5. I've been spending days trying different osx86 distros, reading insanely mac and this forum, and still no avail :(

I think my problem is my video card... I can't get iDeneb nor iPC to work, no matter what I change in BIOS (ACPI changes, ram customization, bios upgrade, disabling items), add to the boot parameters (busratio=20 -F -v -x fsbus=133, graphics mode="") or change in the customization install (different kernels, different nvidia drivers, etc).

I managed to find kexts for my GA-EX58-UD5 from http://www.insanelymac.com/forum/ind...owtopic=149505. I also found a kext for my specific EVGA nvidia geforce gts 250 1024MB graphics card from http://www.insanelymac.com/forum/lof...p/t113489.html.

The problem is, I don't know how to apply the required kext's to my system so it can boot into OSX. My system either panics or gets continual reboots amongst anything I've tried so far, so it must be the kext's that is needed.

If I understand your guide correctly, all I have to do is:
1. Follow this guide to the tee.
2. Insert my custom kext for my machine to customize chameleon and make it boot.

Or is there anything else I should know? Looking for much needed advise!

system specs:
Intel I7 920
Gigabyte GA-EX58-UD5
EVGA NVidia GeForce GTS 250 1024MB
3x2gb OCZ 7-7-7 1600MHZ DDR3
Seagate 1TB 7200.3 (3.5", currently not connected)
Seagate 320GB 7200 (2.5", using for install only)

thorazine74 05-15-2009 10:44 AM

I think you dont need an injecter kext for your graphics card to boot the installation, if its supported by nvidia drivers it will boot though without acceleration (CI/QE). I might be wrong about this though.
You also need voodoo kernel for i7 I think, for the USB Drive it will be easy to use it, you just have to put the mach_kernel.voodoo in the USB drive's root and edit the chameleon's com.apple.Boot.plist to use it instead of mach_kernel.
I'm not sure about booting the installed system from the USB though, I dont know if chameleon uses the kernel from the USB drive or from the partition, if the latter its true you would need to manually copy the kernel file there replacing mach_kernel, if the former its true maybe you need to specify the kernel file using a specific device (like (hd0,1)/mach_kernel.voodoo).

norcimo 05-17-2009 05:02 PM

I have IPC installed, everything runs. No complaints.

I want to install OS X retail, using your method.. but I'm a bit confused. I never delt with kernals.. "vanilla" "voodoo" can you please explain the method I would go with? im unclear concerning this matter....some clarification will help.

2nd.. Has anyone gotten a RAID 0 to boot? if so..how?


My CPU is Intel Duo, and chip set is intelP35.

thanks

SportsGuy 05-18-2009 02:27 AM

Is this portable?

like you can use it on any computer???

Undead Surfer 05-20-2009 12:00 PM

I imaged the retail to an external USB drive that I have. Installed Chameleon and added the AppleDecrypt and the IntelCPUPMDisabler kexts.

I was able to boot to the first installation screen (the one that asks to select your installation language) only to realise that I didn't have any mouse or keyboard.

I tried the VoodooPS2Controller kext and the ApplePS2 one as well but neither seem to work. I don't have a USB Keyboard or Mouse on hand at the moment.

Can you provide any insight into why I can't get Mouse or Keyboard support with the kext installed?

Thanks in advance. Much appreciated.

-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

Decided to go buy a USB Keyboard and Mouse which got me past that problem. Added my drivers to the Extensions folder and ran through the install. It gets stuck halfway into the install. Keeping the log open, the message that I get stuck at is:-

Validating Package Payload.

What could be the cause of this?

thorazine74 05-21-2009 12:37 PM

Quote:

Originally Posted by norcimo (Post 26660)
I have IPC installed, everything runs. No complaints.

I want to install OS X retail, using your method.. but I'm a bit confused. I never delt with kernals.. "vanilla" "voodoo" can you please explain the method I would go with? im unclear concerning this matter....some clarification will help.

2nd.. Has anyone gotten a RAID 0 to boot? if so..how?


My CPU is Intel Duo, and chip set is intelP35.

thanks

Vanilla means original Apple kernel, it only runs on same kind of CPUs as real Apple machines (anything Intel Core I think); voodoo is the modified kernel to run on any processor. If you have an Intel Core Duo or Core 2 Duo you should be able to run the vanilla kernel.

Intel ICH's RAID fakeraid is not supported at all neither for booting nor volumen mounting. Apple software RAID is supported, there are many guides on the matter.

thorazine74 05-21-2009 12:44 PM

Quote:

Originally Posted by SportsGuy (Post 26716)
Is this portable?

like you can use it on any computer???

I'm not sure what you mean, you have to customize the USB Drive Installer to make it work on your hardware, if you include the necessary kexts (and voodoo kernel if needed) you should be able to boot the USB Drive installer on any computer. I just explain the basic procedure, you have to find out the kexts if your hardware is very far from vanilla. To make the USB installer completely universal you would have to include kexts for all of the hardware you want to support, at least for the storage controllers.
From there you can install any place you want, be it a fixed SATA HD, IDE, or a Firewire or another USB Drive, if thats what you mean with portable.

thorazine74 05-21-2009 02:20 PM

Quote:

Originally Posted by Undead Surfer (Post 26845)
I imaged the retail to an external USB drive that I have. Installed Chameleon and added the AppleDecrypt and the IntelCPUPMDisabler kexts.

I was able to boot to the first installation screen (the one that asks to select your installation language) only to realise that I didn't have any mouse or keyboard.

I tried the VoodooPS2Controller kext and the ApplePS2 one as well but neither seem to work. I don't have a USB Keyboard or Mouse on hand at the moment.

Can you provide any insight into why I can't get Mouse or Keyboard support with the kext installed?

Thanks in advance. Much appreciated.

-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

Decided to go buy a USB Keyboard and Mouse which got me past that problem. Added my drivers to the Extensions folder and ran through the install. It gets stuck halfway into the install. Keeping the log open, the message that I get stuck at is:-

Validating Package Payload.

What could be the cause of this?

I'm not sure about that, does it get stuck for a long time? That doesnt sound like an error but if it never continues...
Only idea would be checking the USB Drive and DVD source for errors on the source files. Also check the partition/drive where you are installing to.

About the PS/2 issue, even though its late, keep in mind you have to use only one of either [VoodooPS2] OR [ApplePS2+ACPIPS2Nub], never together. Also for VoodooPS2 I think I had to edit the info.plist to change the OSBundleRequired property from Console to Root. This seems to be a requirement for all extensions to load from /Extra/Extensions succesfully.

Peanut Vendor 05-24-2009 08:27 AM

Success!
 
I finally got everything working :) This is an awesome method, by the way. It really helped me get my stuff working. Thank-you!

Using this guide, I ended up installing Chameleon using the Installer found here: http://www.insanelymac.com/forum/ind...owtopic=149505

By following the README instructions for the installer, you can customize for your own needs. The installer has some great functionality to update boot.plist and a few other things. Of course, this is installer is customized with kext's for a Gigabyte GA-EX58-UD5 specific motherboard.

So here's my hardware configuration and here's what I had to do to make it work. Motherboard: Gigabyte GA-EX58-UD5. Video Card: EVGA Nvidia GeForce GTS 250. Processor: Intel i7 920.

KEXT: I had to use the kext's for my motherboard and processor from the install I mentioned above. I also had to use the customized NVinject kext found here: http://www.insanelymac.com/forum/lof...p/t113489.html. The normal NVinject kext didn't seem to work.

KERNEL: The 9.7 Vanilla kernel didn't seem to work; nor does the 9.6 Voodoo kernel. Of all things, I have to specify the Vanilla 9.63 kernel, otherwise it doesn't work.

BOOT FLAGS: I had to use busratio=20 cpus=1 fsb=133. Still do have to use them.

OSX86Tools: Another great resource to modify your hackintosh once you're in.

My next goal is to get Quartz Extreme working instead of NVinject. Other then that, everything works great! Super fast, super fun. blows my old ibook G4 out of the water :)

thorazine74 05-24-2009 11:28 AM

Glad you got it to work!
I didnt know you would need an injector to boot the installation, maybe because your graphics card is not supported yet? So with nvinject you get to boot with GTS 250 but you dont have video acceleration?
About the kernel, it was reported 9.7 vanilla kernel added support for Core i7? Did you install 10.5.6 with 9.7 kernel? Or you installed 10.5.6 with voodoo 9.63 and then updated to 10.5.7+9.7 vanilla and it didnt work?

lemon 06-11-2009 11:22 AM

Problem on first reboot.
 
I have dumped the 10.5.6 retail image to a 8 GB usb stick, where I have installed then chameleon 2 rc1, as well as Disabler.kext and AppleDecrypt.ketx, nothing more.
The mainboard is the old intel 945gclf, with the single core atom (which worked wonderfully before, with kalyway).
It boots without problems and I can do the complete install (of course I get at the end the error saying it cannot be made bootable).
After the reboot, it boots from the usb stick, I select then the hard disks, and starts to boot normally, but when the moment arrives to show the login screen (well, the welcome screen as it is a fresh installation), all I get is a grey screen with the mouse cursor, which can be moved freely, but nothing more happens. I've let it like that for some time (a couple hours) but nothing happens.
I've tried to boot with -f, -x, -v, but it's always the same, and I can't see any kind of strange error message.
Someone has tried this method on this (or a similar) board? Is some other extension needed? (that would be strange, as the installation runs perfectly)

thorazine74 06-11-2009 04:20 PM

It seems that you got it to boot successfully but the desktop doesnt work completely (you say get a mouse cursor, you also get that too when booting with -f or -x?) so I would suspect the problem is related to the graphics, that Atom boards got Intel 950 Onboard graphics I think, so maybe you need to add or mod some of the Intel graphics kexts to boot even in safe mode. I got no experience with Intel at all, but I would find out if you need some graphics injector for the specific Intel card you got there.

lemon 06-11-2009 07:18 PM

Well, with kalyway it worked ok without selecting any graphics driver or injector (well, stuck at 1024x768 and without QE/CI), it was only needed to activate QE/CI and resolution changing.
The result is the same with -x or -f

thorazine74 06-12-2009 08:35 AM

I dont know maybe something changed between 10.5.2 and 10.5.6 in Intel 950 support, if it boots all the way to the desktop but it doesnt work there that would be my first guess.
Only other idea would be checking if your USB bus works good, I got something similar when the USB reset was not being done properly (though on different hardware), try disabling USB Storage and Legacy support in the BIOS or use Chameleon2's EHCI/UCHI Reset options.

lemon 06-12-2009 10:01 AM

Well, finaly solved it.
As I thoght, one kext was missing. Now I'm not there and I don't remember which one it was, something about AppleSMBIOS.
Graphics were stuck at 1024x768 and without QE/CI, as expected, but worked.
Then, by using a DSDT.aml which was already prepared for this board, graphics work wonderfully with QE/CI at 1920x1200 on my 24" monitor, without using any special driver, injector or kext string.

slowkilling 06-14-2009 08:11 AM

i'm noob here....

i'm follow all instruction above but boot.......blue screen..stack from there :'(


any advice ?
partition
1. HFS+
2. NTFS (XP)
3. FAT32(DATA)

Intel Core 2 Duo T5300
gma950
Realtek ALC883

thorazine74 06-15-2009 09:19 AM

Booting from the USB installer or after the installation? Have you tried verbose mode? (-v flag)
If its after the installation check the post above, you may need to install an SMBIOS enabler, maybe the OP can tell you which one exactly.

slowkilling 06-21-2009 05:48 AM

I'm sorry.. busy this time..

Yes i try to boot with -v -x -f

But after all kind of text come out and blue screen and stuck...

maybe GMA950 thing,

but Finally I got this Mac working in my laptop with other way

but the question VGA & Sound driver on /Extra/Extension folder didnt work for me. it's possible to load from /Extra/Extensions?

thank's and sorry about my english

thorazine74 06-21-2009 10:12 AM

I got no experience with Intel GMA950 so I cant be of much help there, the other poster said he needed an SMBIOS enabler and/or maybe a custom DSDT to get QE/CI working.
About sound depends on the kext you are using for it, VoodooHDA needs some other dependency kexts in /Extra/Extensions. A patched AppleHDA.kext should work as it is but I dont know for sure.

01001 01-05-2010 03:46 AM

makin the usb install
 
i have a a real mac g5 and thats where im makin the usb install and a few pc machines im tryin to follow ur instrutions but i got lost at editing the OSINSTALL.MPKG! how do you edit it?

what do i use to edit it with? when i open the usb stick i dont see whats in picture for step 2!

can i get sum help?:mad:please!!!!

i have the retail dvd, usb drive, Chameleon v1.0.12, and the 123 bootloader for my mobo!!!

and thank you for this post !!!!!