LinuxQuestions.org
Share your knowledge at the LQ Wiki.
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
  Search this Thread
Old 04-14-2009, 10:11 AM   #1
samengr
Member
 
Registered: Jan 2008
Posts: 59

Rep: Reputation: 15
ntp server is not working on RHEL5 - any help?


Hi,

I am unable to configure what is wrong with my NTP server. I am using RHEL5.

# vi /etc/ntp.conf
restrict default kod nomodify notrap nopeer noquery
restrict -6 default kod nomodify notrap nopeer noquery

restrict 127.0.0.1
restrict -6 ::1

restrict 192.168.182.0 mask 255.255.255.0 nomodify notrap

server 0.rhel.pool.ntp.org
server 1.rhel.pool.ntp.org
server 2.rhel.pool.ntp.org

server 127.127.1.0 # local clock
fudge 127.127.1.0 stratum 10

driftfile /var/lib/ntp/drift

keys /etc/ntp/keys

========

# cat /etc/sysconfig/ntpd
# Drop root to id 'ntp:ntp' by default.
OPTIONS="-u ntp:ntp -p /var/run/ntpd.pid"

# Set to 'yes' to sync hw clock after successful ntpdate
SYNC_HWCLOCK=no

========

[root@station1 ~]# /etc/init.d/ntpd restart
Shutting down ntpd: [ OK ]
Starting ntpd: [ OK ]

# tail -f /var/log/messages

Apr 13 09:03:48 station1 ntpd[15334]: ntpd exiting on signal 15
Apr 13 09:03:48 station1 ntpd[15473]: ntpd 4.2.2p1@1.1570-o Wed Nov 29 15:19:23 UTC 2006 (1)
Apr 13 09:03:48 station1 ntpd[15474]: precision = 2.000 usec
Apr 13 09:03:49 station1 ntpd[15474]: Listening on interface wildcard, 0.0.0.0#123 Disabled
Apr 13 09:03:49 station1 ntpd[15474]: Listening on interface wildcard, ::#123 Disabled
Apr 13 09:03:49 station1 ntpd[15474]: Listening on interface lo, ::1#123 Enabled
Apr 13 09:03:49 station1 ntpd[15474]: Listening on interface eth0, fe80::20c:29ff:fe50:5d6#123 Enabled
Apr 13 09:03:49 station1 ntpd[15474]: Listening on interface lo, 127.0.0.1#123 Enabled
Apr 13 09:03:49 station1 ntpd[15474]: Listening on interface eth0, 192.168.182.10#123 Enabled
Apr 13 09:03:49 station1 ntpd[15474]: kernel time sync status 0040
Apr 13 09:03:49 station1 ntpd[15474]: frequency initialized -156.124 PPM from /var/lib/ntp/drift

########

[root@station1 ~]# telnet 192.168.182.10 123
Trying 192.168.182.10...
telnet: connect to address 192.168.182.10: Connection refused
telnet: Unable to connect to remote host: Connection refused

[root@station1 ~]# /etc/init.d/iptables stop
Flushing firewall rules: [ OK ]
Setting chains to policy ACCEPT: filter [ OK ]
Unloading iptables modules: [ OK ]

[root@station1 ~]# telnet 192.168.182.10 123
Trying 192.168.182.10...
telnet: connect to address 192.168.182.10: Connection refused
telnet: Unable to connect to remote host: Connection refused

#####

# pgrep ntpd
15474
# ll /var/run/ntpd.pid
-rw-r--r-- 1 root root 5 Apr 13 09:03 /var/run/ntpd.pid

#####

# ntpq -p
remote refid st t when poll reach delay offset jitter
================================================== ============================
193.41.86.177 9.200.78.141 3 u 56 64 5 110.158 1080306 19.590
mirror-01.mainl 192.36.143.152 2 u 53 64 7 48.015 1080306 26.405
ntp2.cines.fr 195.83.180.3 2 u 52 64 7 45.342 1080306 54.446
LOCAL(0) .LOCL. 10 l 53 64 7 0.000 0.000 0.002


but I am unable to connect to port 123 even the following output shows its listening

# netstat -an | grep 123
udp 0 0 192.168.182.10:123 0.0.0.0:*
udp 0 0 127.0.0.1:123 0.0.0.0:*
udp 0 0 0.0.0.0:123 0.0.0.0:*
udp 0 0 fe80::20c:29ff:fe50:5d6:123 :::*
udp 0 0 ::1:123 :::*
udp 0 0 :::123 :::*

Can any body help me to sort this out?

Many thanks.
 
Old 04-14-2009, 10:16 AM   #2
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1984Reputation: 1984Reputation: 1984Reputation: 1984Reputation: 1984Reputation: 1984Reputation: 1984Reputation: 1984Reputation: 1984Reputation: 1984Reputation: 1984
NTP = UDP, telnet = TCP... ain't gonna happen!
 
  


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



Similar Threads
Thread Thread Starter Forum Replies Last Post
GUI not working in RHEL5 SERVER addition sethrajnish Linux - Software 4 07-03-2009 03:30 AM
How to make one rhel5 server control passwords for several rhel5 servers. folkrm Linux - Newbie 3 03-11-2009 03:17 PM
NTP issues RHEL5 adamjohnson01 Red Hat 4 06-06-2008 08:23 AM
ntp server on Fedora 8 not working Tom Douglas Linux - Server 2 03-08-2008 07:27 PM
NTP cannot use server, NTP -d can jerryvapps Linux - Newbie 0 07-28-2004 03:22 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

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

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration