problem sync time

Gloupus

New Member
Jan 12, 2010
7
0
1
Hello,

Sorry for my basic english

Sync time doesn't run. I have modified the file ntp.conf. See below edit file.
Code:
# /etc/ntp.conf, configuration for ntpd; see ntp.conf(5) for help
driftfile /var/lib/ntp/ntp.drift
 
# Enable this if you want statistics to be logged.
#statsdir /var/log/ntpstats/
statistics loopstats peerstats clockstats
filegen loopstats file loopstats type day enable
filegen peerstats file peerstats type day enable
filegen clockstats file clockstats type day enable
 
# You do need to talk to an NTP server or two (or three).
#server ntp.your-provider.example
adacv.ad.etat-de-vaud.ch
time-e.netgear.com
# pool.ntp.org maps to about 1000 low-stratum NTP servers. Your server will
# pick a different set every time it starts up. Please consider joining the
# pool: <http://www.pool.ntp.org/join.html>
server 0.pool.ntp.org
server 1.pool.ntp.org
server 2.pool.ntp.org
server 3.pool.ntp.org
server 0.fr.pool.ntp.org
server 1.fr.pool.ntp.org
server 2.fr.pool.ntp.org
# Access control configuration; see /usr/share/doc/ntp-doc/html/accopt.html for
# details. The web page <http://support.ntp.org/bin/view/Support/AccessRestrictions>
# might also be helpful.
#
# Note that "restrict" applies to both servers and clients, so a configuration
# that might be intended to block requests from certain clients could also end
# up blocking replies from your own upstream servers.
# By default, exchange time with everybody, but don't allow configuration.
restrict -4 default kod notrap nomodify nopeer noquery
restrict -6 default kod notrap nomodify nopeer noquery
# Local users may interrogate the ntp server more closely.
restrict 127.0.0.1
restrict ::1
# Clients from this (example!) subnet have unlimited access, but only if
# cryptographically authenticated.
#restrict 192.168.123.0 mask 255.255.255.0 notrust
 
# If you want to provide time to your local subnet, change the next line.
# (Again, the address is an example only.)
#broadcast 192.168.123.255
# If you want to listen to time broadcasts on your local subnet, de-comment the
# next lines. Please do this only if you trust everybody on the network!
#disable auth
#broadcastclient

If anybody has any idea ?

Regards

D.Gehrig
 
It may indeed be a FW problem

you can check by installing ntpdate, stopping ntp and run ntpdate to check if you can reach your ntp server
Code:
# aptitude install ntpdate
# /etc/init.d/ntp stop
# ntpdate adacv.ad.etat-de-vaud.ch
you should see, it it works
Code:
neptune2:/etc/qemu-server# ntpdate ntpserver.xcvxcvcxv.fr
12 Jan 09:53:12 ntpdate[11171]: adjust time server 192.168.118.4 offset -0.004245 sec
If it doesn't work you will get an error msg :

Code:
neptune2:/etc/qemu-server# ntpdate adacv.ad.etat-de-vaud.ch
Error : Name or service not known
12 Jan 09:54:41 ntpdate[11192]: can't find host adacv.ad.etat-de-vaud.ch

12 Jan 09:54:41 ntpdate[11192]: no servers can be used, exiting

Don't forget, once fixed to restart the ntp server ;)
 
Thanks you for the reply "Dietmar" and "whinpo"

Dietmar, i have installed ntpdate and i have following your instructions and it works . Thanks you very much for the solution.

Regards

D.Gehrig
 
Last edited: