LinuxQuestions.org
Go Job Hunting at the LQ Job Marketplace
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices

Reply
 
LinkBack Search this Thread
Old 10-09-2013, 03:58 PM   #16
michaelk
Moderator
 
Registered: Aug 2002
Posts: 11,539

Rep: Reputation: 676Reputation: 676Reputation: 676Reputation: 676Reputation: 676Reputation: 676

I can not tell for sure but I would assume that the version of ntp installed does not have that option since your start up script uses ntpdate.

Post the output of the command:
ntpd --version

The -g option was in implemented in version 4.

Look in the /etc/ directory for a file named release i.e. redhat-release or lsb_release. The contents will contain the version.
 
Old 10-09-2013, 04:00 PM   #17
jpollard
Senior Member
 
Registered: Dec 2012
Location: Washington DC area
Distribution: Fedora, CentOS, Slackware
Posts: 1,697

Rep: Reputation: 426Reputation: 426Reputation: 426Reputation: 426Reputation: 426
Depends on the distribution.

There should be configuration options for ntpd (ought to be in the same place as the filespecification and port options...)
 
Old 10-09-2013, 04:05 PM   #18
tony359
LQ Newbie
 
Registered: May 2013
Posts: 29

Original Poster
Rep: Reputation: Disabled
ntpd - NTP daemon program - Ver. 4.2.4p4
OS Version is Debian 5.0.7

Thanks for your help guys!

Last edited by tony359; 10-09-2013 at 04:10 PM.
 
Old 10-09-2013, 04:19 PM   #19
michaelk
Moderator
 
Registered: Aug 2002
Posts: 11,539

Rep: Reputation: 676Reputation: 676Reputation: 676Reputation: 676Reputation: 676Reputation: 676
Running ntpdate at start up performs the same function as the -g option. I would remove the -x from the start up script since kernel time discipline is disabled with this option.
 
Old 10-12-2013, 03:58 AM   #20
tony359
LQ Newbie
 
Registered: May 2013
Posts: 29

Original Poster
Rep: Reputation: Disabled
Thanks, but my question is slightly different.

Having an unreliable NTP server - that is a windows clock not syncronised to anything - is it possible to ask the NTP deamon to sync to it no matter what? But not one off, regularly. Stepping time when needed.

Thanks.
 
Old 10-12-2013, 07:09 AM   #21
jpollard
Senior Member
 
Registered: Dec 2012
Location: Washington DC area
Distribution: Fedora, CentOS, Slackware
Posts: 1,697

Rep: Reputation: 426Reputation: 426Reputation: 426Reputation: 426Reputation: 426
That is what ntpd does. It uses a reference clock to cause updates to the local clock.

It works as long as the clocks are reasonably close together (about 10 minutes difference). Now if the Windows reference clock server isn't compatible with ntpd, then it won't work.
 
Old 10-12-2013, 08:29 AM   #22
tony359
LQ Newbie
 
Registered: May 2013
Posts: 29

Original Poster
Rep: Reputation: Disabled
but it won't work if the source clock is not stable. I understand that for working properly ntpd needs to see a stable and reliable clock on the other side. A CMOS clock is not, hence ntpd will reject the source.

What I'm wondering is: is there a way to tell ntpd to be less fussy about the source and just sync it (stepping won't be a problem) without rejecting it?
 
Old 10-12-2013, 08:37 AM   #23
jpollard
Senior Member
 
Registered: Dec 2012
Location: Washington DC area
Distribution: Fedora, CentOS, Slackware
Posts: 1,697

Rep: Reputation: 426Reputation: 426Reputation: 426Reputation: 426Reputation: 426
Not necessarily. I have run ntpd using both a local CMOS clock, and synched other systems to that clock. No problem.
 
Old 10-12-2013, 08:43 AM   #24
tony359
LQ Newbie
 
Registered: May 2013
Posts: 29

Original Poster
Rep: Reputation: Disabled
Ok, so let's rephrase the question: is there a way to tell NTPD to be less fussy and just sync the clock no matter what happens to the remote NTP? Cannot use a schedule instance of ntpdate. I appreciate that ntpd is designed to keep the clock synced to the millisecond, but this is not my need and for several reasons which are out of my reach I cannot change much on my systems.
 
Old 10-12-2013, 09:05 AM   #25
michaelk
Moderator
 
Registered: Aug 2002
Posts: 11,539

Rep: Reputation: 676Reputation: 676Reputation: 676Reputation: 676Reputation: 676Reputation: 676
The hardware clock is only used to set the system clock at boot up. ntp will also discipline the hardware clock for drift as well as keep its time synced.

It isn't impossible if your system clocks remain fairly stable that you could keep other computers synced using a free running clock.

So why is running ntpdate via cron not an option? You can change the offset limit as well as how often ntp polls a server. However, I am doubt that this will fix the problem.
 
Old 10-12-2013, 11:42 AM   #26
tony359
LQ Newbie
 
Registered: May 2013
Posts: 29

Original Poster
Rep: Reputation: Disabled
it's a long story. I can amend the ntp.conf file, but nothing else.

The point is that I understand that when ntpd feels the source clock is unstable, it won't trust it anymore. I had a long conversation on this forum with a very kind forumer about the subject. It makes sense to me, but as said my server does not need to be precise down to the millisecond. I would be happy if it was down to 30 seconds. I agree that stepping time with ntpdate every x minutes would be ideal, but that's not an option. That's why I'm wondering if ntpd can be configured to follow a clock which would normally reject.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
NTP client is not syncing to ntp server LittleMaster Linux - Newbie 6 04-05-2013 02:37 PM
[SOLVED] NTP configuration in client to synchronize with NTP server. antnish Linux - General 12 04-01-2013 01:49 PM
[SOLVED] NTP Error - "Failed to drop root privileges." mikewc02 Linux - Software 6 01-04-2011 11:28 AM
ntp drift file in /etc/ntp instead of /var/lib/ntp - suggestion for a patch in Slack niels.horn Slackware 16 05-07-2009 07:35 PM
[root] Changing time without using ntp/ntpdate ? frenchn00b Linux - Newbie 1 07-22-2007 03:53 PM


All times are GMT -5. The time now is 02:39 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration