[ntp:questions] moving from ntpdc to ntpq

Mike Cook michael.cook at sfr.fr
Fri Feb 27 07:50:35 UTC 2015


"Ceux qui sont prêts à abandonner une liberté essentielle pour obtenir une petite et provisoire sécurité, ne méritent ni liberté ni sécurité."
Benjimin Franklin

> Le 27 févr. 2015 à 08:22, catherine.wei1989 at gmail.com a écrit :
> 
> On Saturday, February 7, 2015 at 11:25:02 AM UTC+8, Harlan Stenn wrote:
>> Pretty much the same thing, except with ":config addpeer ..." and
>> ":config unconfig ...".
>> 
>> I think...
>> 
>> Please feel free to add examples to:
>> 
>> http://support.ntp.org/Support/MonitoringAndControllingNTP
>> http://support.ntp.org/Dev/DeprecatingNtpdate
>> 
>> H
>> Richard writes:
>>> What is ntpq's equivelant of -c "addpeer <ntp host>"   and  -c "unconfig
>>> <ntp host>"  ?
>>> 
>>> 
>>> I just upgraded from ntp 4.2.6 to 4.2.8 and ntpdc isn't connecting to my
>>> local ntpd. According to the ntpdc man page:
>>> 
>>> "ntpdc is deprecated. Please use ntpq(1) instead - it can do everything
>>> ntpdc used to do,"
>>> 
>>> 
>>> In ntpq how do I do the equivalent of ntpdc's -c "addpeer "  or -c
>>> "unconfig" commands?
>>> 
>>> 
>>> Here is part of what previously did with ntpdc:
>>> 
>>> /usr/sbin/ntpc -4 -c "keyid 5" -c "passwd  mypassword" \
>>> -c "addpeer  <ntp server> "  localhost
>>> 
>>> 
>>> _______________________________________________
>>> questions mailing list
>>> questions at lists.ntp.org
>>> http://lists.ntp.org/listinfo/questions
>>> 
> 
> Hi, if I add :config in front of addpeer, it seems that an authentication is required. When I specify the keyid to 0, it said "invalid key identifier ».

The MD5 keys file used for passwords does not contain a 0 key. Starts at 1.
ex:
apache2  ntpkey_md5_cubieez  ntpkey_MD5key_cubieez.3634012029
root at cubieez:/usr/local/etc# cat ntpkey_MD5key_cubieez.3634012029
# ntpkey_MD5key_cubieez.3634012029
# Fri Feb 27 08:47:09 2015

 1 MD5 w$It8qF.&yq)G[bhV:<>  # MD5 key
 2 MD5 1,fLb0.0uu;!4sI4>%os  # MD5 key
 3 MD5 GSz/.']5D_l6>DMjpL2D  # MD5 key
 4 MD5 TAM=C][4j=a,`X$sm=2e  # MD5 key
 5 MD5 PW.s^OS_kE+X~qKUm\:.  # MD5 key
 6 MD5 D;<4!c.swl:~cUvM!J^3  # MD5 key
 7 MD5 wq[?.c}S{lV79HX{`tle  # MD5 key
 8 MD5 SJxajDfU*2`A+i}%R{M>  # MD5 key
 9 MD5 AGBp[Z]iEH at z1:?T3!OA  # MD5 key
10 MD5 Al'jlgWLE?:IH;mCegNJ  # MD5 key


> 
> _______________________________________________
> questions mailing list
> questions at lists.ntp.org
> http://lists.ntp.org/listinfo/questions


More information about the questions mailing list