 |
 |
Internet Time Server Settings
|
 |
|
 |
|
Addicted to MacNN
Join Date: Jan 2000
Location: Stoneham, MA, USA
Status:
Offline
|
|
I use the setting to set the time by apples time server over the internet on my server. Its 10.2 Server. Anyway I wanna set how often it checks its time. Its always way off, I think becuase its an old computer, a Power Tower Pro, and its battery must be dying or something. But its like 10 minutes off by the end of the day. So I wanna change it so it checks its time every hour or two. I know there must be a setting in some files somewhere to change that right?
|
|
|
| |
|
|
|
 |
|
 |
|
Mac Elite
Join Date: May 2001
Status:
Offline
|
|
No, wrong.
Apple goes a strange way there. Instead of synchronizing the time in fixed intervals by getting the time from a timeserver with 'ntpdate', they try to get a full ntpd (time server daemon) running, but they don't provide a valid configuration file (at least last time I checked), so the time gets set exactly once on boot and that's it (try to check whether 'ntpd' is running for you or not).
Your options are:
- either to write a working /etc/ntp.conf, then it would check the time permanently and synchronize your clock (and perhaps have your Mac acting as timeserver). But each time you select the time server settings in the preferences, they would overwrite the conf file with their unusuable version (write protecting it might help there).
- or to turn the time server stuff completely off and call 'ntpdate' periodically (manually, with chron, or whatever else) which would just perform a time synchronisation on each call. I think that's what 99.3% of the OS X users need and want.
-
|
|
|
| |
|
|
|
 |
|
 |
|
Addicted to MacNN
Join Date: Jan 2000
Location: Stoneham, MA, USA
Status:
Offline
|
|
aaaah i gotcha. I don't wanna do it manually, I've never set up a cron before any easy instructions on how to do it?
|
|
|
| |
|
|
|
 |
|
 |
|
Dedicated MacNNer
Join Date: Dec 2002
Location: someplace
Status:
Offline
|
|
|
|
|
|
| |
|
|
|
 |
|
 |
|
Addicted to MacNN
Join Date: Jan 2000
Location: Stoneham, MA, USA
Status:
Offline
|
|
actually if i just
it automatically uses apple's time server and updates it. I just don't know how to set up a cron thinggie so it will do this every hour or two.
|
|
|
| |
|
|
|
 |
|
 |
|
Mac Elite
Join Date: Dec 2001
Location: Atlanta, GA, USA
Status:
Offline
|
|
Originally posted by l008com:
actually if i just
it automatically uses apple's time server and updates it. I just don't know how to set up a cron thinggie so it will do this every hour or two.
In a text file with UNIX linefeeds, put this:
Code:
# field allowed values
# ----- --------------
# minute 0-59
# hour 0-23
# day of month 1-31
# month 1-12
# day of week 0-7
0 * * * * /usr/sbin/ntpdate >> /var/log/ntpdate.log 2>&1
Save that as something like "root_crontab.txt". Then, on the command-line, type:
When it asks for the password give it. You are now logged in a root shell. Then, type:
Code:
crontab root_crontab.txt
You can verify that it worked by typing:
This will list out the crontab. The command as specified will set the clock every hour on the hour. You can tweak it as needed using the info in comments I included.
|
|
Mac Pro 2x 2.66 GHz Dual core, Apple TV 160GB, two Windows XP PCs
|
| |
|
|
|
 |
|
 |
|
Mac Elite
Join Date: Dec 2001
Location: Atlanta, GA, USA
Status:
Offline
|
|
By the way, ntpd is running fine on my ibook:
Code:
[dshaw@flybook ~] ps -auxw | grep ntpd
root 380 0.0 0.0 1556 268 ?? Ss 14Aug03 0:26.22 ntpd -f /var/run/ntp.drift -p /var/run/ntpd.pid
|
|
Mac Pro 2x 2.66 GHz Dual core, Apple TV 160GB, two Windows XP PCs
|
| |
|
|
|
 |
|
 |
|
Mac Elite
Join Date: May 2001
Status:
Offline
|
|
Originally posted by Arkham_c:
By the way, ntpd is running fine on my ibook:
Code:
[dshaw@flybook ~] ps -auxw | grep ntpd
root 380 0.0 0.0 1556 268 ?? Ss 14Aug03 0:26.22 ntpd -f /var/run/ntp.drift -p /var/run/ntpd.pid
Interesting.. when I checked it would not run properly, but as I said, that's some time ago. If I remember correctly it was because Apple had only that one time server you select in the conf file and nothing to compare to, not even the internal clock. So as others have time sync problems as well I figure it can't be all fixed now, maybe it just runs without updating much. Do you get some reasonable output if you type 'ntpq -p'?
-
|
|
|
| |
|
|
|
 |
|
 |
|
Dedicated MacNNer
Join Date: Dec 2002
Location: someplace
Status:
Offline
|
|
Originally posted by l008com:
...it automatically uses apple's time server and updates it. I just don't know how to set up a cron thinggie so it will do this every hour or two. [/B]
I would suggest not using time.apple.com as the time server; rather, use one of the NIST servers I linked to above.
|
|
|
| |
|
|
|
 |
|
 |
|
Mac Elite
Join Date: May 2001
Status:
Offline
|
|
Originally posted by gatorparrots:
I would suggest not using time.apple.com as the time server; rather, use one of the NIST servers I linked to above.
Would you mind telling us why you suggest not using time.apple.com?
Of course you can choose another, there are hundreds of time servers that don't restrict access to them, however many have access policies that should be respected.
-
|
|
|
| |
|
|
|
 |
 |
|
 |
|
|
|
|
|

|
|
 |
Forum Rules
|
 |
 |
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
|
HTML code is Off
|
|
|
|
|
|
 |
 |
 |
 |
|
 |
|