Self service - set network time.

PeterG
Contributor II

I have a number of users who let their laptop batteries run down to 0% and their Date/Time resets to 2001.
They cannot unlock their date/Time system prefs because they do not have admin passwords.
They cannot VPN to the home office because VPN doesn't like the wrong time.

I want to make a Self Service button that they can use to Sync the time.

I'm using ntpdate -u time.apple.com to force them to re-sync.
• The command works like a charm on my computer in terminal.
• The command (loaded into the JSS as a script) works like a charm executing via Casper Remote.
• A policy, with Self service enabled, scoped to all users, the same script included, hangs forever...

I looked in console (after adding -s) and cannot find out where the problem is.

Has anyone else done this same thing successfully or had a script that works well otherwise just freak out Self Service?

4 REPLIES 4

cbrewer
Valued Contributor II

I'm using the systemsetup command and it's been getting the job done. I'm not using a script - just having a policy run the command directly.

systemsetup -setusingnetworktime on -setnetworktimeserver time.yourserver.com

alexjdale
Valued Contributor III

This doesn't address your Self Service issue, but why is the time not updating automatically on its own? I would think this can be addressed without users having to take action.

PeterG
Contributor II

I did create a different "systemsetup -setusingnetworktime on -setnetworktimeserver time.yourserver.com" button, in Self Service, to set it for the user but he reports that they year is still 2001.

perhaps I should set yet another button to toggle -setusingnetworktime to off so when he turns it on it will sync. ??

...and our longstanding policy had been to point to an internal time server and now that I have someone out of the country... they are not 'on our network'

jhalvorson
Valued Contributor

I have seen this issue when the time gets reset to something very old and if the Firewall is enabled DCHP can't obtain an address. Something to do with timestamp of one of the related files is too old. No DCHP means the clock can't update.

I think Self Service will fail if the Mac's time varies too much from the JAMF Server's time, depending on the settings within Computer Management Framework Settings > Security. Do you currently have "Enable Certificate-Based Communication" enabled? Consult with your JAMF tech support person before making any changes within that section!!!