When using bootcamp to dual boot, you may notice the time gets out of sync on the Mac side. When it’s off by more than five minutes, Directory Authentication will not work so I created this plist file that will force OS X to sync it’s time on boot. Save the code to a file named
com.apple.timesync.plist
and place it in the foler
/Library/LaunchDaemons
The code causes OSX to update it’s time when the login window appears and anytime the BootPicker log file is modified. I use BootPicker to allow students to choose between XP or OS X when the machines boots.

<?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>Label</key>
<string>com.apple.timesync</string>
<key>ProgramArguments</key>
<array>
<string>/usr/sbin/ntpdate</string>
<string>-buv</string>
</array>
<key>RunAtLoad</key>
<true/>
<key>WatchPaths</key>
<array>
<string>/Library/logs/bp.log</string>
</array>
</dict>
</plist>

You can also create this file easily by using Lingon. Check it out if you haven’t heard of it before.