Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!

Set Boot Camp partition to boot to Windows via command line UNIX
I work in academia in a large 1:1 deployment of around 6,000 MacBooks. At one point in time when we made the switch to Macs an assessment testing software developer had not made a universal binary app yet and their PPC app just would not run right on Intel based Macs. So, I had to create and deploy a dual boot image for them. The thought had crossed my mind on how to allow managed users (with no admin rights) the ability to dual boot? I cannot use any boot loader that runs in EFI either because I have to have firmware passwords on the Macs via security protocols.

So, I dug around in Terminal and was messing around with the bless command. If you execute this command:

/usr/sbin/bless --device /dev/disk0s3 --setBoot --legacy --nextonly

It will set the partition that lives on /dev/disk0s3 to boot for next restart only, and the -legacy option supports booting an OS that does not support EFI boot loaders. Since Windows still requires older technology like a BIOS to actually load from, the -legacy option gives that support.

In the end I wrapped this command up in a Casper policy and allowed users to execute it via self service, which is a web-like app that users can execute policies on their own, and they run as root. So, the user just clicked on the dual boot policy and hit install. The Self Service app ran the bless command and a command to force a reboot.

It is probably possible to accomplish this with an AppleScript saved as an application or something similar.

[crarko adds: I haven't tested this one.]
    •    
  • Currently 3.50 / 5
  You rated: 2 / 5 (6 votes cast)
 
[12,608 views]  

Set Boot Camp partition to boot to Windows via command line | 2 comments | Create New Account
Click here to return to the 'Set Boot Camp partition to boot to Windows via command line' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
Set Boot Camp partition to boot to Windows via command line
Authored by: duped on Jun 02, '11 08:18:37AM

This is the same feature BootPicker takes advantage of to allow non-admin users to choose Mac OS or Windows. BootPicker appears on top of the Mac OS X log in screen:
http://www.apple.com/education/resources/bootpicker/

The bless command can also be used for night time restarts of the system using an Apple Remote Desktop task so that Windows maintenance can be run.

Additionally, the Boot Camp 3 and later Windows drivers allow for use of the command line from within Windows to run the same command:
http://support.apple.com/kb/HT3802



[ Reply to This | # ]
Set Boot Camp partition to boot to Windows via command line
Authored by: tom larkin on Jun 02, '11 11:28:01AM

Yes, but boot picker does not allow for a firmware password to be present on your Macs if I recall. Is that still not the case?



[ Reply to This | # ]