Solaris / OpenSolarisThis forum is for the discussion of Solaris, OpenSolaris, OpenIndiana, and illumos.
General Sun, SunOS and Sparc related questions also go here. Any Solaris fork or distribution is welcome.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I'm trying to setup an NTP server on one of my sun boxes, but I'm not getting it to work. It seems pretty strait forward but I seem to be missing something. Here is my procedure. Am I doing something wrong?
Code:
NTP Master
1. Create the file /etc/inet/ntp.conf with the following
entries:
server 127.127.1.0
driftfile /etc/ntp.drift
2. Create the file /etc/ntp.drift with the following entry:
0.0
3. Bounce NTP service.
#> /etc/rc2.d/S74xntd stop
#> /etc/rc2.d/S74xntd start
4. Check Status
#> ntpq
ntpq> peers
NTP Clients
1. Create the file /etc/inet/ntp.conf with the following entries:
server <NTP Master IP [do not use hostname]>
driftfile /etc/ntp.drift
2. Create the file /etc/ntp.drift with the following entry:
0.0
3. Bounce NTP service.
#> /etc/rc2.d/S74xntd stop
#> /etc/rc2.d/S74xntd start
4. Check Status
#> ntpq
ntpq> peers
When I get into ntpq and type peers I'm getting "Read: Connection Refused" when I try this on the server and the client that I'm testing on. Any suggestions would be great!
I was thinking it was 127.0.0.1, but according to the manuals I find it's correct. Could it be that the UDP port is blocked or something? Is there a file that you can edit to unblock ports? I know it uses UDP 123 and maybe that's what not being allowed or something... Thanks for the help!
Distribution: OpenBSD 4.6, OS X 10.6.2, CentOS 4 & 5
Posts: 3,660
Rep:
After you start the xntpd service, do a netstat -an |grep 123 and see which interfaces it's listening on and what addresses it's bound to.
Personally, I would recommend OpenNTPD as it's much less complex than xntpd and it was designed with security from the ground-up, unlike the other NTP daemons that attempted to get precision accuracy and slapped on security later. Understandably, that's probably not supportable if you have to roll it out to a bunch of clients as a special package, rather than using what's bundled with Solaris, but it might make sense to use OpenNTPD as your daemons and only use xntpd for clients.
I suggest you to read this quick howto. If you want more details you can follow the links at the bottom, to the Sun's blueprint series.
I guess you problem is that you don't have a "broadcast 224.0.1.1.." in your conf file.
Well, one thing I would recommend is to use svcadm to restart ntpd rather than bouncing it via the scripts.
The other item of note is that IIRC from my Cisco days... 127.0.0.0/8 is ALL reserved for localhost, but many server platforms only respond on 127.0.0.1.
When I do a "netstat -an | grep 123" it doesn't come up with anything. Am I correct to think that that port is being blocked by something or it's disabled?
Oh... So even though I'm starting the service, it's not running. I don't get an error when I start it using "/etc/init.d/xntpd start" so I wonder what's killing it.
I also forgot to add in the previous post that broadcast 224.0.1.1 is in the ntp.config file. I've even tried it as multicastclient with no effect.
Doh... I can't do that... It's very complicated but the short of it is that all our development is on version 8 so I can't change that... This is driving me crazy, but it should just work and I can't figure out why. From everything that I've read (thanks for the suggestions) I'm setting it up all correctly.
Note: driftfile and statsdir are under /var/ntp (I guess that's not a real problem in your case) and my ntp.drift contains "0.000"
Also take a look at /var/adm/messages to see if you find any error.
Well, looking at my configuration file I see that it is almost exactly like what you've posted bathory. The only thing missing was the ttl 4. I added that with the same result of it still not working. I also disabled the "Enable auth monitor" but that didn't help either. What a pain this is.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.