- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- What is the sync interval time in NTP
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-09-2010 09:29 AM
тАО03-09-2010 09:29 AM
I would like to test NTP configuration in my test server.
So I have just now configured NTP client for time synchronization.
After that the time has been synced with NTP server.
Ex:
#date
Tue Mar 9 11:19:00 CST 2010
Then I would like to check the synchronization with NTP server.
So that I have changed the time using the command date.
Ex:
# date 030910382010
Tue Mar 9 10:38:11 CST 2010
I have changed the time to 30 mins later.
Then I have waited for about 3 hrs to see whether the time is syncing with NTP server.
Still it is not synced with NTP server.
Still the time remail 30 mins later than NTP server.
What is the sync interval time in NTP?
When can we see the NTP server time in local serer?
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-09-2010 09:38 AM
тАО03-09-2010 09:38 AM
Re: What is the sync interval time in NTP
> I have changed the time to 30 mins later.
Then I have waited for about 3 hrs to see whether the time is syncing with NTP server.
Still it is not synced with NTP server.
You will never synchronize. NTP abandons its efforts if the difference in time between your server and an NTP source is ~ 1000 seconds (~ 16+ minutes). This prevents insane time corrections.
Read this chapter:
http://docs.hp.com/en/B2355-91060/ch04.html
In particular, see the trouble-shooting section and the 'ntpq' utility.
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-09-2010 10:22 AM
тАО03-09-2010 10:22 AM
Re: What is the sync interval time in NTP
Now the difference is 8 mins between local server and NTP server.
I have changed the time accordingly.
Now also I am waiting for 10 mins still the time is not synchronized with NTP server.
How to solve this.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-09-2010 11:23 AM
тАО03-09-2010 11:23 AM
Re: What is the sync interval time in NTP
In general, about 5-6 poll cycles (at 64-seconds by default) occur before synchronization. You can verify that you have reached (associated) with a time source with 'ntpq -p'. An asterisk ("*") will precede the the IP or node name to which synchronization has occured. A "+" indicates that the source is a candidate.
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-09-2010 12:11 PM
тАО03-09-2010 12:11 PM
Solutionntp does not do instant time correction. It can't.
If your system was running fast and ntp rolled the time back, a database program like Oracle would immediately crash.
I've done it, not pretty.
ntp makes adjustments over time. It runs the clock slightly slower if its running fast and slightly faster if its behind.
If the difference is under an hour, it can take a while for this process to complete.
ntpq is a good utility for seeing what is going on.
SEP
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-09-2010 04:38 PM
тАО03-09-2010 04:38 PM
Re: What is the sync interval time in NTP
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-09-2010 05:20 PM
тАО03-09-2010 05:20 PM
Re: What is the sync interval time in NTP
The default for 'xntpd' (NTP) is to *step* the server time rather than slew it. It is therefore generally advisable to configure 'ntpdate' to run at boot-time; step the clock; and then let 'xntpd' make small, further step or slew adjustments as necessary.
To cause 'ntpdate' to run as startup and thus adjust any large time delta immediately and once, set the following variables in '/etc/rc.config.d/netdaemons':
# export NTPDATE_SERVER=mytimeserver.xyz.com
# export XNTPD=1
To cause 'xntpd' to slew, do:
# export XNTPD_ARGS=-x
See the 'xntpd' manpages for more information.
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-09-2010 05:23 PM
тАО03-09-2010 05:23 PM
Re: What is the sync interval time in NTP
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-10-2010 07:29 AM
тАО03-10-2010 07:29 AM
Re: What is the sync interval time in NTP
I have some questions:
1)Instead of configuring NTP, can I just run ntpdate ntp_server_name in crontab to update the time at 5 mins time interval?
2)What is the disadvantage of doing that?
3)I have configured NTP and ntpdate in startup also. the time is syncing with NTP server. Suddenly one day I have changed the time manually using the command date to be 1 hr later, then if I am restarting the server, the ntpdate will be ran at startup and fetch the time form NTP server, at this situation, will my oracle corrupt?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО03-10-2010 07:53 AM
тАО03-10-2010 07:53 AM
Re: What is the sync interval time in NTP
> 1)Instead of configuring NTP, can I just run ntpdate ntp_server_name in crontab to update the time at 5 mins time interval?
Why? The 'xntpd' daemon is just that, a process that runs all the time, making very small corrections. It is spawned once and runs "forever",
> 2)What is the disadvantage of doing that?
Your time control may not be as accurate and you impose the overhead of process creation when you don't need to do so (see #1, above).
> 3)I have configured NTP and ntpdate in startup also. the time is syncing with NTP server. Suddenly one day I have changed the time manually using the command date to be 1 hr later, then if I am restarting the server, the ntpdate will be ran at startup and fetch the time form NTP server, at this situation, will my oracle corrupt?
Changing time forward isn't as harmful as changing it backwards! However, a good policy with databases and other time-sensitive applications is to stop them before a manual time adjustment. In a "good" configuration, at startup, a valid time is established before your database(s) are started.
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО04-15-2010 04:03 AM
тАО04-15-2010 04:03 AM
Re: What is the sync interval time in NTP
Never do that! I see this all the time in Linux systems and it is a leftover from 30 years ago when the time was simply 'jammed' into the system. Accuracy to within 5 minutes was considered acceptable, but there wasn't any Oracle or Sybase stuff to worry about. It defeats the purpose of NTP and that is to provide EXACTLY 86,400 seconds per day. If you run applications such as databases, especially on multiple systems, they may become corrupt if you add or drop even one second.
NTP keeps the time accurate to less than 128 milliseconds. Running ntpdate 'jumps' the time forward or backward and your 24 hour day no longer will have the right number of seconds. cron jobs may not run or worse, they will run multiple times. ntpdate should only be used at bootup where it should already be setup in /etc/rc.config.d/netdaemons. ntpdate will be run long before any applications and databases have started.
>> 2)What is the disadvantage of doing that?
Lousy timekeeping, unexpected jumps in time, or worse, you do not use a reliable NTP server and someone messes with the time on the NTP server. Then all the machines that depend on the NTP server will be messed up.
>> 3)I have configured NTP and ntpdate in startup also. the time is syncing with NTP server.
That is as expected. Be sure to run ntpq -p to verify that your server is synchronized.
>> Suddenly one day I have changed the time manually using the command date to be 1 hr later, then if I am restarting the server, the ntpdate will be ran at startup and fetch the time form NTP server, at this situation, will my oracle corrupt?
Why did you change the time? NEVER change the time on an active server. If you changed it by 1 hour, I will guess that your login did not have $TZ set correctly. To verify the system time, always use date -u and compare that with a Zulu or UTC clock. HP-UX has the ability to run 86,400 separate timezones at the same time, all defined by the current value of $TZ -- which is set by /etc/TIMEZONE in /etc/profile. But anyone can change TZ to a new value (or worse, unset TZ and get the default timezone) and the date command will look incorrect.
Will Oracle be corrupt? Certainly there is a possibility for corruption if you (or any root user) changes the time. Tell all the root users to NEVER change the time while any applications are running.
> What is the sync interval time in NTP?
Once every 64 seconds, the time is evaluated. If the NTP server's time is too far away from the current time (ie, more than 1000 seconds, then the NTP time is ignored. If you were to run ntpdate, it would immediately 'jump' the time, thus causing problems with databases and applications.
After several hours, xntpd will calculate the dependability of the time servers, pick the best one based on reliable responses, and will double the poll time to 128 seconds. If the round trip time for the poll and the returned values continue to be stable, the time is again increased to a maximum of 1024 seconds (once every 17 minutes).
>> Then I would like to check the synchronization with NTP server.
Use ntpq -p
>> So that I have changed the time using the command date.
>> Ex:
>> # date 030910382010
>> Tue Mar 9 10:38:11 CST 2010
>> I have changed the time to 30 mins later.
Don't ever do this on a running system. Use ntpq -p and also look in syslog.log for the current status of xntpd.
Bill Hassell, sysadmin