erlug
[Top] [All Lists]

Re: [Erlug] Network Time Protocoll

To: erlug@xxxxxxxxxxxxxx
Subject: Re: [Erlug] Network Time Protocoll
From: Sythos <sythos@xxxxxxxxxx>
Date: Thu, 25 Nov 2004 13:14:48 +0100
On Thu, Nov 25, 2004 at 01:05:31PM +0100, Andrea Paolini wrote:
> > Ho provato ntp-simple e ntp-refclock (sempre con ntp-server installato), 
> ntp-refclock se non hai una sorgente esterna (GPS, DCF77, orologio
> atomico) non ti serve.

attacco di panico dalla sindrome "cazzo ho seguito la doc ma non va"

> > ma non trovo modo di metterli in ascolto sulla udp/123
> server pinco.example.com
> server pallo.example.net
> server pera.example.org

fatto, tempo.ien.it, ntp1.ien.it, ntp2.ien.it

> in ntp.conf dovrebbe essere suffciente.

allora qualcosa tocca somewhere

> > (dalla doc solo il secondo potrebbe mentre il
> > primo per motivi che pur avendo letto non comprendo non e' consigliato)
> 
> Uh ? Dove è scritto ?

dalle note in fondo ai vari "apt-cache show ntp-[flavour]" ma posso aver
male interpretato

> ntpd non gira sotto inetd, è un demone standalone. Ma se con ntpd
> attivo lanci un bel:
> # lsof -i4 -a -p `cat  /var/run/ntpd.pid`
> cosa ti dice ?

lui dice:
# lsof -i4 -a -p `cat  /var/run/ntpd.pid`
COMMAND   PID USER   FD   TYPE DEVICE SIZE NODE NAME
ntpd    24804 root    4u  IPv4 863747       UDP *:ntp
ntpd    24804 root    5u  IPv4 863748       UDP localhost:ntp
ntpd    24804 root    6u  IPv4 863749       UDP vortex.sythos.net:ntp
ntpd    24804 root    9u  IPv4 863761       UDP 192.168.0.255:ntp


aggiungo per completare il quadro:

dal syslog

Nov 25 12:20:25 vortex ntpd[23650]: Listening on interface wildcard,
0.0.0.0#123
Nov 25 12:20:25 vortex ntpd[23650]: Listening on interface lo,
127.0.0.1#123
Nov 25 12:20:25 vortex ntpd[23650]: Listening on interface eth0,
192.168.0.3#123
Nov 25 12:20:25 vortex ntpd[23650]: kernel time sync status 0040
Nov 25 12:25:56 vortex ntpd[23677]: ntpd 4.2.0a@1:4.2.0a-11-r Tue Jul 27
04:55:05 CEST 2004 (1)

dai proc
# ps aux | grep ntpd
root     24804  0.2  1.6   3952  3952 ?        SLs  13:09   0:00
/usr/sbin/ntpd -p /var/run/ntpd.pid


dal firewall
# iptables -L | grep ntp
ACCEPT     tcp  --  anywhere             anywhere            tcp dpt:ntp
ACCEPT     udp  --  anywhere             anywhere            udp dpt:ntp


da nmap
# nmap -p 123 localhost

Starting nmap 3.75 ( http://www.insecure.org/nmap/ ) at 2004-11-25 13:10
CET
Interesting ports on localhost (127.0.0.1):
PORT    STATE  SERVICE
123/tcp closed ntp

Nmap run completed -- 1 IP address (1 host up) scanned in 0.045 seconds


PS: si lo so sono un caso disperato ^_^


-- 

Sythos - http://www.sythos.net

  ()  ASCII Ribbon Campaign - against html/rtf/vCard in mail
  /\                        - against M$ attachments
    

<Prev in Thread] Current Thread [Next in Thread>