Author Topic: Default Partition -- syntax?  (Read 5192 times)

0 Members and 1 Guest are viewing this topic.

jbreher

  • Observer
  • Posts: 18
Default Partition -- syntax?
« on: July 19, 2010, 02:27:16 AM »
OK, I now have my system dual booting SL & W7. The rest of the family prefers Windows. I'd like to set this machine to default to boot Win. I can't seem to make this happen. Is there a syntax mismatch between rdiskMsN and hd(X,Y)?

Relevant info:
Code: [Select]
hostname:Extra username$ pwd
/Extra
hostname:Extra username$ diskutil list
2010-07-18 18:21:31.479 diskutil[173:903] _CFGetHostUUIDString: unable to determine UUID for host. Error: 35
/dev/disk0
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:     FDisk_partition_scheme                        *750.2 GB   disk0
   1:             Windows_FAT_32 WD-MB-MUSIC             750.2 GB   disk0s1
/dev/disk1
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:      GUID_partition_scheme                        *1.0 TB     disk1
   1:                        EFI                         209.7 MB   disk1s1
   2:                  Apple_HFS LifeHack                500.1 GB   disk1s2
   3:       Microsoft Basic Data 7pro64                  499.8 GB   disk1s3
hostname:Extra username$ cat com.apple.Boot.plist
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Kernel</key>
<string>mach_kernel</string>
<key>Kernel Flags</key>
<string></string>
<key>Timeout</key>
<string>5</string>
<key>Theme</key>
<string>Blackosx_Mactico_I'm_a_Mac_Theme</string>
<key>"Default Partition"</key>
<string>hd(1,3)</string>
</dict>
</plist>
hostname:Extra username$
As you might guess, "LifeHack" is the SL install, and "7pro64" is Win.

Bonus question for extra credit: Should I be worrying about the UUID error listed above?
Gigabyte GA-EP45-UD3P / Intel Celeron Dual Core E1400 2.0 GHz / 800 MHz FSB / ASUS EN8400GS Silent/HTP/512M PCIe x16
4GiB (2x2) G.Skill DDR2-10666, PC2-8500, 2048MB x 2, CL-5-5-5-15 2.0~2.1V DRAM / 750 GB Seagate Barracuda 7200.11 SATA HDD ST3750330AS / hp dvd1170i SATA DL DVD
EFI (empty) / iPC 10.5.6 / Win 7 pro x64
... oh yeah, and an i7 17" MBP

zef

  • Administrator
  • Posts: 265
Re: Default Partition -- syntax?
« Reply #1 on: July 19, 2010, 02:37:11 AM »
Press the TAB key while you're at the GUI, then you'll get the actual hd(x,y) values for the partitions.
ASUS P8Z68-V PRO/GEN3 | i5-2500k | 16GB RAM | GTX560 | Keyboard | Mouse | Devilsound DAC

jbreher

  • Observer
  • Posts: 18
Re: Default Partition -- syntax?
« Reply #2 on: July 19, 2010, 05:17:08 AM »
Thanks. I restarted, and hit tab at the first GUI screen. Here's what it said:
Code: [Select]
Darwin/x86 boot v5.0.132- Chameleon v2.0-RC1 r
Build date: 2009-07-23 21:23:08
4094 MB memory
VESA v3.0 14MB (NVIDIA)
Use ^v keys to select the startup volume

    hd(0,2) LifeHack
    hd(0,3) 7pro64
    hd(1,1) windows FAT32

Press Enter to start up Darwin/x86 with no options, or you can:
 Type -v and press Enter to start up with diagnostic messages
 Type ? and press Enter to learn about advanced startup options.

So I changed to the following:
Code: [Select]
hostname:~ username$ cat /Extra/com.apple.Boot.plist
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Kernel</key>
<string>mach_kernel</string>
<key>Kernel Flags</key>
<string></string>
<key>Timeout</key>
<string>5</string>
<key>Theme</key>
<string>Blackosx_Mactico_I'm_a_Mac_Theme</string>
<key>"Default Partition"</key>
<string>hd(0,3)</string>
</dict>
</plist>
hostname:~ username$

but it is  still booting the LifeHack partition.

I also tried hitting tab at gui and entering '?'. It gives the following error:
Code: [Select]
File not found: bt(0,0/Extra/BootHelp.txt
Any thing else I can try?
Gigabyte GA-EP45-UD3P / Intel Celeron Dual Core E1400 2.0 GHz / 800 MHz FSB / ASUS EN8400GS Silent/HTP/512M PCIe x16
4GiB (2x2) G.Skill DDR2-10666, PC2-8500, 2048MB x 2, CL-5-5-5-15 2.0~2.1V DRAM / 750 GB Seagate Barracuda 7200.11 SATA HDD ST3750330AS / hp dvd1170i SATA DL DVD
EFI (empty) / iPC 10.5.6 / Win 7 pro x64
... oh yeah, and an i7 17" MBP

Azimutz

  • VoodooLabs
  • Posts: 420
  • Paranoid Android
Re: Default Partition -- syntax?
« Reply #3 on: July 19, 2010, 06:27:00 AM »
jbreher,
remove the "" from the key name:
Code: [Select]
<key>Default Partition</key>
Also, you're still using RC1; latest release is RC4. You can also use RC5 from the repository.. check my signature for compiled binaries. RC5 will fix "error: 35" and that BootHelp.txt not found on Text Mode, though you can hit Tab again to get back to Gui and check Help there, on RC4 and previous.
« Last Edit: July 20, 2010, 04:03:33 AM by Azimutz »
 System & Patches: http://goo.gl/i961
 Chameleon:
- trunk builds: http://goo.gl/9G1Hq
- pref pane: http://goo.gl/OL2UT

jbreher

  • Observer
  • Posts: 18
Re: Default Partition -- syntax?
« Reply #4 on: July 20, 2010, 03:16:37 AM »
Thanks Azimutz. I had thought I had seen a requirement for a token with embedded spaces to be surrounded with quotes, but I must have just made that up.

After removing the quotes, it is booting Win by default.

Just to ensure that I am clear, to upgrade, do I just write the new boot0 to the IPL (first 440 bytes?) of the 'MBR' (sector 0 of the HDD), write the new boot1h to the PBR (sector 0 of the active partition),  and write the new boot to /boot?
Gigabyte GA-EP45-UD3P / Intel Celeron Dual Core E1400 2.0 GHz / 800 MHz FSB / ASUS EN8400GS Silent/HTP/512M PCIe x16
4GiB (2x2) G.Skill DDR2-10666, PC2-8500, 2048MB x 2, CL-5-5-5-15 2.0~2.1V DRAM / 750 GB Seagate Barracuda 7200.11 SATA HDD ST3750330AS / hp dvd1170i SATA DL DVD
EFI (empty) / iPC 10.5.6 / Win 7 pro x64
... oh yeah, and an i7 17" MBP

Azimutz

  • VoodooLabs
  • Posts: 420
  • Paranoid Android
Re: Default Partition -- syntax?
« Reply #5 on: July 20, 2010, 06:31:14 AM »
jbreher,
now that you mention, some of the keys on the BootHelp.txt have "" including Default Partition, while others not; as far as i know none uses "", though i have the same feeling as you... some comment some were in the code maybe??...

Yep, the installation is basically that; in your case, you may want to try using boot0hfs instead of the usual boot0..
check here why, to make a choice.
The RC5 from my signature is just a RC4 bin package with updated files, no mods. Already has the now renamed to fdisk440 so you can just cd to i386 folder and do:
Code: [Select]
sudo ./fdisk440 -f boot0hfs -u -y /dev/rdiskX; sudo dd if=boot1h of=/dev/rdiskXs2; cp boot /don't forget to
Code: [Select]
diskutil listfirst and check device identifier, OS X has the habit to change order.
Whatever you do, always make sure you have plan B!

Any doubt just yell :)

p.s.: if you downloaded RC5 r184 from my sig, get it again.. i forgot to add the optimized png´s to Default theme folder.

p.s.s: only now i noticed you had another topic, were you were getting good help and you opened this one only to ask this?! you could/should have done it on the other.. just a thought.
« Last Edit: July 20, 2010, 08:48:06 AM by Azimutz »
 System & Patches: http://goo.gl/i961
 Chameleon:
- trunk builds: http://goo.gl/9G1Hq
- pref pane: http://goo.gl/OL2UT

jbreher

  • Observer
  • Posts: 18
Re: Default Partition -- syntax?
« Reply #6 on: July 21, 2010, 03:54:00 AM »
OK, I dl'd your RC5 r164, and installed it. (Although I did need to sudo to cp boot / as well.)

I then used the diskpart on my win 7 install DVD to set the win partition as active.

At this point, it looks like all is well. I can boot into whatever partition desired. I am told that this my also allow me to hibernate windows (not that I have any call to do so).

It is BootHelp.txt that implies the quotes are necessary:
Quote
  "Default Partition"       Sets the default boot partition,
    =hd(x,y)                  where 'x' is the disk number, 'y' the partition number.

BTW, BootHelp.txt is now available with tab at the GUI, and my UUID error is gone. Outstanding.
Gigabyte GA-EP45-UD3P / Intel Celeron Dual Core E1400 2.0 GHz / 800 MHz FSB / ASUS EN8400GS Silent/HTP/512M PCIe x16
4GiB (2x2) G.Skill DDR2-10666, PC2-8500, 2048MB x 2, CL-5-5-5-15 2.0~2.1V DRAM / 750 GB Seagate Barracuda 7200.11 SATA HDD ST3750330AS / hp dvd1170i SATA DL DVD
EFI (empty) / iPC 10.5.6 / Win 7 pro x64
... oh yeah, and an i7 17" MBP

Azimutz

  • VoodooLabs
  • Posts: 420
  • Paranoid Android
Re: Default Partition -- syntax?
« Reply #7 on: July 21, 2010, 07:53:34 AM »
Nice :)
you had to
Code: [Select]
sudo cp boot /
because the file was previously copied with sudo and i forgot that detail :P; i usually copy "boot" over Finder, because it doesn't need to have root permissions and i update it many times a day, these days!
I have the feeling i read the "" thing some were else besides BootHelp.txt... if it was the case i will find it again!
 System & Patches: http://goo.gl/i961
 Chameleon:
- trunk builds: http://goo.gl/9G1Hq
- pref pane: http://goo.gl/OL2UT