Junos OS

last person joined: 3 days ago 

Ask questions and share experiences about Junos OS.
  • 1.  the M7i NTP log error

    Posted 06-22-2011 20:24

    Hi,all,

    On my M7i,I found some logs about NTP,as:

    Jun 23 09:37:28 CENTER-M7-1 xntpd[1314]: bind() fd 9, family 2, port 123, addr 128.0.0.1, in_classd=0 flags=0 fails: Can't assign requested address

    Jun 23 09:28:52 CENTER-M7-1 xntpd[1314]: bind() fd 9, family 2, port 123, addr 128.0.0.1, in_classd=0 flags=0 fails: Can't assign requested address
    Jun 23 09:33:09 CENTER-M7-1 xntpd[1314]: bind() fd 9, family 2, port 123, addr 128.0.0.1, in_classd=0 flags=0 fails: Can't assign requested address
    Jun 23 09:35:18 CENTER-M7-1 xntpd[1314]: bind() fd 9, family 2, port 123, addr 128.0.0.1, in_classd=0 flags=0 fails: Can't assign requested address
    What the log meaning?
    Thank you.


  • 2.  RE: the M7i NTP log error

    Posted 06-23-2011 06:19

    Hi Zhoukangle,

     

    the log entries mean that NTPD is trying to listen on 128.0.0.1, but that address does not seem to be configured on the router.

     

    My question is, how can this possibly be? Can you post your full NTP configuration?

     

    Thanks,

     Saverio



  • 3.  RE: the M7i NTP log error

    Posted 06-23-2011 20:22

    Hi,Saverio,

    Thank you for your response,I will upload the config later,thank you.

    (P.S:f  or your question:"how can this possibly be?",I can not get the meaningSmiley Happy)



  • 4.  RE: the M7i NTP log error

    Posted 06-24-2011 07:02

    Hi Zhoukangle,

     

    > (P.S:f  or your question:"how can this possibly be?",I can not get the meaning:smileyhappy:)

     

    .. it just meant that I cannot really understand how is it possible that this can happen..

     

    From the logs, it would look like ntp is trying to listen to 128.0.0.1 (which is a martian address), and this is failing.

     

    The only explanation I can think of, is that for some reason in the NTP configuration the source address is set to this, rather than 127.0.0.1 (which is the loopack address) but this sounds really improbable..

     

    Another thing that could trigger this message is the presence of 128.0.0.1, and a loopback/interface firewall filter which would kill martian addresses.

     

    Do you have 128.0.0.1 as a second loopback (or on any other interface) by any chance?

     

    ..I realize these are all wild guess..

     

    Saverio



  • 5.  RE: the M7i NTP log error

    Posted 06-27-2011 05:19
      |   view attached

    Hi,Saverio,

    Thank you for your response.I do not config the 128.0.0.1 in any configration.you can see the files which I uploaded ,thank you.

     

     

    Attachment(s)

    txt
    NTP-CONFIG&LOG.txt   2 KB 1 version


  • 6.  RE: the M7i NTP log error

    Posted 06-24-2011 07:13

    Hi Zhoukangle,

    I've seen a Problem Report long ago that stated that messages of such kind
    come from peculiarities of FreeBSD's xntpd daemon which is used by JunOS.
    I'm sure you can safely ignore them.

    If you want to filter them out, a following workaround should work

    file messages {
        any any;
        ntp none;
    }



  • 7.  RE: the M7i NTP log error

    Posted 06-27-2011 05:21

    Hi,pk,

    Thank you for your response.And I want to know the meaning for "family 2, port 123, addr 128.0.0.1, in_classd=0 flags=0 fails: Can't assign requested address",can you tell me ?

    Thank you.



  • 8.  RE: the M7i NTP log error

    Posted 06-27-2011 05:36

    Hi

     

    In my case on SRX240, I see that NTP has binded to port 123 on address 128.0.0.1 which is a martian address (and not in the config, of course):

     

    lab@srxA-1> show system connections | match 123
    udp4       0      0  128.0.0.1.123                                 *.*
    udp4       0      0  *.123                                         *.*

     

    In you case messages mean that you do not "have" 128.0.0.1 address. This should not be significant - in any case, 2nd line shows that ntp is working on *.123, i.e., on "any" address. Probarbly your messages will go away after upgrade.



  • 9.  RE: the M7i NTP log error
    Best Answer

    Posted 06-27-2011 10:08

    > And I want to know the meaning for "family 2, port 123, addr 128.0.0.1, in_classd=0 flags=0 fails: Can't assign requested address",can you tell me ?

     

     

    Hi Zhoukangle,

     

    This is just an error string that is returned when the 'bind' system call (which is used by ntpd to start listening to an address) fails.

     

    The actual error is 'Can't assign requested address', i.e. xntpd is trying to listen to an address which is not configured on the router.

    The rest is just debugging information which is printed to help developer pinpoint the issue. Specifically:

     

    'family 2' means IPv4

    port 123, addr 128.0.0.1: these are the port ntpd is trying to listen to.

    flags: are optional flags that are not used in this case.

    in_classd is another flag which indicates if the socket is trying to listen to a multicast address (it isn't in this case).

     

    The 'bind' system call is documented on any good unix reference:

    http://en.wikipedia.org/wiki/Berkeley_sockets#bind.28.29

     

    It would appear (from pk's post above) that on some platforms (SRX?), 128.0.0.1 is used for some internal purpose.

     

    On your M7i, this does not seem to be the case, so ntpd complains that it cannot listen to that address.

     

    It is a harmless message, but if it is present on newer releases, I would suggest to contact JTAC and ask them to open a low-priority PR to have this resolved (this is most probably a trivial code change).

     

    .. making Junos better is also our job!

     

    I hope it helps, let me know if you need more information..

      Saverio



  • 10.  RE: the M7i NTP log error

    Posted 06-29-2011 07:29

    Hi,pk & Saverio,

    Thank you.Smiley Very Happy