Thursday, August 16, 2012

Boot Options

The boot: prompt waits for you to type advanced startup options.
If you don't type anything, the computer continues starting up normally. It
uses the kernel and configuration files on the startup device, which it also
uses as the root device.

Advanced startup options use the following syntax:

[device]<kernel> [arguments]

Example arguments include

device: rd=<BSD device name>       (e.g. rd=disk0s2)
rd=*<IODeviceTree path>    (e.g. rd=*/PCI0@0/CHN0@0/@0:1)

kernel: kernel name                (e.g. "mach_kernel" - must be in "/" )

flags: -v (verbose)                -s (single user mode)
-x (safe mode)              -f (ignore caches)
-F (ignore "Kernel Flags" specified in boot configuration file)

"Graphics Mode"="WIDTHxHEIGHTxDEPTH" (e.g. "1024x768x32")

kernel flags                       (e.g. debug=0x144)
io=0xffffffff                      (defined in IOKit/IOKitDebug.h)

Example: mach_kernel rd=disk0s1 -v "Graphics Mode"="1920x1200x32"

If the computer won't start up properly, you may be able to start it up
using safe mode.  Type -x to start up in safe mode, which ignores all
cached driver files.

Special booter hotkeys:
F5            Rescans optical drive.
F10           Scans and displays all BIOS accessible drives.

Special booter commands:
?memory       Displays information about the computer's memory.
?video        Displays VESA video modes supported by the computer's BIOS.
?norescan     Leaves optical drive rescan mode.

Additional useful command-line options:
config=<file>             Use an alternate Boot.plist file.

Options useful in the org.chameleon.Boot.plist file:
Wait=Yes|No             Prompt for a key press before starting the kernel.
"Quiet Boot"=Yes|No     Use quiet boot mode (no messages or prompt).
Timeout=8               Number of seconds to pause at the boot: prompt.
"Instant Menu"=Yes      Force displaying the partition selection menu.

"Default Partition"     Sets the default boot partition,
=hd(x,y)|UUID|"Label"    Specified as a disk/partition pair, an UUID, or a
label enclosed in quotes.

"Hide Partition"        Remove unwanted partition(s) from the boot menu.
=partition               Specified, possibly multiple times, as hd(x,y), an
[;partition2 ...]       UUID or label enclosed in quotes.

"Rename Partition"      Rename partition(s) for the boot menu.
=partition <alias>       Where partition is hd(x,y), UUID or label enclosed
[;partition2 <alias2>   in quotes. The alias can optionally be quoted too.

GUI=No                  Disable the GUI (enabled by default).
"Boot Banner"=Yes|No    Show boot banner in GUI mode (enabled by default).
ShowInfo=No             Disables display of partition and resolution details.
"Boot Banner"=No will also disable this info.
"Legacy Logo"=Yes|No    Use the legacy grey apple logo (disabled by default).

PciRoot=<value>         Use an alternate value for PciRoot (default value 0).

UseKernelCache=Yes|No   Yes will load pre-linked kernel and will ignore /E/E
and /S/L/E/Extensions.mkext.
Default is No but Yes if you use Lion on a Raid partition.

KeyLayout=keymap        Use to change the keyboard mapping of the bootloader
(e.g. KeyLayout=mac-fr)

GraphicsEnabler=Yes|No  Automatic device-properties generation for gfx cards.
AtiConfig=<cardcfg>   Use a different card config, e.g. AtiConfig=Megalodon.
AtiPorts=<value>      Specify the number of ports, e.g. AtiPorts=2.
UseAtiROM=Yes|No      Use an alternate Ati ROM image
(path: /Extra/<vendorid>_<devid>_<subsysid>.rom)
UseNvidiaROM=Yes|No   Use an alternate Nvidia ROM image
(path:  /Extra/<vendorid>_<devid>.rom)
VBIOS=Yes|No          Inject NVIDIA VBIOS into device-properties.
display_0=<value>     Inject alternate value of display-cfg into NVDA,Display-A@0 (HEX).
display_1=<value>     Inject alternate value of display-cfg into NVDA,Display-B@1 (HEX).
EnableHDMIAudio=Yes      Inject HDMI audio for NVIDIA

EthernetBuiltIn=Yes|No  Automatic "built-in"=yes device-properties generation
for ethernet interfaces.

USBBusFix=Yes           Enable all USB fixes below:
EHCIacquire=Yes         Enable the EHCI fix (disabled by default).
UHCIreset=Yes           Enable the UHCI fix (disabled by default).
USBLegacyOff=Yes        Enable the USB Legacy fix (disabled by default).

ForceHPET=Yes|No        Force Enable HPET.

Wake=No                 Disable wake up after hibernation (default: enabled).
ForceWake=Yes           Force using the sleepimage (disabled by default).
WakeImage=<file>        Use an alternate sleepimage file.
(default path is /private/var/vm/sleepimage).

DropSSDT=Yes            Skip the SSDT tables while relocating the ACPI tables.
DSDT=<file>             Use an alternate DSDT.aml file
(default paths:
/DSDT.aml /Extra/DSDT.aml bt(0,0)/Extra/DSDT.aml).

GenerateCStates=Yes     Enable auto generation of processor idle sleep states
GeneratePStates=Yes     Enable auto generation of processor power performance
states (P-States).
CSTUsingSystemIO=Yes    New C-State _CST generation method using SystemIO
registers instead of FixedHW.

EnableC2State=Yes       Enable specific Processor power state, C2.
EnableC3State=Yes       Enable specific Processor power state, C3.
EnableC4State=Yes       Enable specific Processor power state, C4.

SMBIOS=<file>           Use an alternate SMBIOS.plist file
(default paths:
/Extra/SMBIOS.plist bt(0,0)/Extra/SMBIOS.plist).

SMBIOSdefaults=No       Don't use the Default values for SMBIOS overriding if
smbios.plist doesn't exist, factory values are kept.

"Scan Single Drive"     Scan the drive only where the booter got loaded from.
=Yes|No               Fix rescan pbs when using a DVD reader in AHCI mode.
Rescan=Yes              Enable CD-ROM rescan mode.
"Rescan Prompt"=Yes     Prompts for enable CD-ROM rescan mode.
SystemId=<UUID>         Set manually the system id UUID,
SMUUID in smbios config (reserved field) isn't used.
SystemType=<n>          Set the system type where n is between 0..6
(default =1 (Desktop)
md0=<file>              Load raw img file into memory for use as XNU's md0
ramdisk. /Extra/Postboot.img is used otherwise.