RE: How to change STRATUM on linux. - NTP

This is a discussion on RE: How to change STRATUM on linux. - NTP ; Yes you can, and i finally found how. On the server, this is my ntp.org configuration: server 127.127.1.0 fudge 127.127.1.0 stratum 5 restrict 127.127.1.0 I also have a second one with higher stratum. After restarting ntpd and waiting some minutes ...

+ Reply to Thread
Results 1 to 3 of 3

Thread: RE: How to change STRATUM on linux.

  1. RE: How to change STRATUM on linux.


    Yes you can, and i finally found how.

    On the server, this is my ntp.org configuration:

    server 127.127.1.0
    fudge 127.127.1.0 stratum 5
    restrict 127.127.1.0

    I also have a second one with higher stratum.

    After restarting ntpd and waiting some minutes i get this when doing a
    ntptrace:

    localhost.localdomain: stratum 6, offset 0.000000, synch distance
    0.011279

    So, basically ntp uses its local clock and then puts a stratum 6 on it.
    My local clock is sync'ed with a windows2003 server like this:

    Net time -S x.x.x.x set , and put in crontab.

    My 2003 server is sync'ed with the daytime protocol to a internet time
    server.

    I need a good stratum value because my cisco devices (switches etc) will
    not sync if the stratum is 16.
    So this is my cisco configuration:

    service timestamps debug datetime localtime
    service timestamps log datetime localtime
    clock timezone GMT 1
    ntp server x.x.x.x ==> this is no X ofcourse in my real
    config!
    ntp server x.x.x.x prefer
    clock summer-time GMT recurring last sunday march 02:00 last sunday
    october 03:00 60

    Best to put 2 time servers in cisco devices.
    And this works for a 100%!
    I can see in my cisco device with "show ntp associations"

    address ref clock st when poll reach delay offset
    disp
    *~x.x.x.x 127.127.1.0 6 373 1024 377 3.1 0.28
    0.3
    ~x.x.x.x 127.127.1.0 8 1012 1024 377 2.4 -760.9
    103.9
    * master (synced), # master (unsynced), + selected, - candidate, ~
    configured

    (changed the x ofcourse).

    So, it can be done.
    Cheers,
    Phil.


    -----Original Message-----
    From: questions-bounces@lists.ntp.isc.org
    [mailto:questions-bounces@lists.ntp.isc.org] On Behalf Of Steve Kostecke
    Sent: woensdag 18 oktober 2006 14:39
    To: questions@lists.ntp.isc.org
    Subject: Re: How to change STRATUM on linux.

    On 2006-10-18, Philippe Dhont Sea-ro wrote:

    > i also want to sync all my cisco switches with that ntp server but
    > that's not working and probably because the cisco switch thinks that
    > the ntp server has stratum 16 (that's what it says in show ntp
    > associations) so it thinks it is not reliable.


    If your "ntp server" is reporting that it is at Stratum-16 then it is
    most likely not synchronized to a time source. You need to fix this
    first.

    Please post the output from 'ntpq -p your.ntp.server' and the active
    lines from your ntp.conf.

    > Is there a way so that i can my the cisco thinks that the linux server


    > has stratum 1 so that it will take that host as reliable and configure


    > its time with it ?


    First you have to make sure that your "ntp server" is really working.

    > in other words, how can i change on linux the stratum value ?


    You can't do it directly (except in certain circumstances.

    --
    Steve Kostecke
    NTP Public Services Project - http://ntp.isc.org/

    _______________________________________________
    questions mailing list
    questions@lists.ntp.isc.org
    https://lists.ntp.isc.org/mailman/listinfo/questions


    _______________________________________________
    questions mailing list
    questions@lists.ntp.isc.org
    https://lists.ntp.isc.org/mailman/listinfo/questions


  2. RE: How to change STRATUM on linux.


    > server 127.127.1.0
    > fudge 127.127.1.0 stratum 5


    > So, basically ntp uses its local clock and then puts a stratum 6 on it.
    > My local clock is sync'ed with a windows2003 server like this:


    > Net time -S x.x.x.x set , and put in crontab.


    I'm missing something. Why set the clock via crontab rather
    than telling ntpd to use it as a server? The latter will
    get the stratum right without a local clock.

    --
    The suespammers.org mail server is located in California. So are all my
    other mailboxes. Please do not send unsolicited bulk e-mail or unsolicited
    commercial e-mail to my suespammers.org address or any of my other addresses.
    These are my opinions, not necessarily my employer's. I hate spam.


  3. Re: How to change STRATUM on linux.

    On 2006-10-19, Philippe Dhont Sea-ro wrote:

    > Yes you can, and i finally found how.
    >
    > On the server, this is my ntp.org configuration:
    >
    > server 127.127.1.0
    > fudge 127.127.1.0 stratum 5
    > restrict 127.127.1.0


    This is the special case I mentioned previously. Refclocks (including
    the often misused Undisciplined Local Clock) can be fudged to arbitrary
    strata.

    Most refclocks default to stratum 0. The Undisciplined Local Clock, or
    LocalCLK, defaults to stratum 5; the fudge line you used is redundant
    unless you are changing the stratum to something else.

    > I also have a second one with higher stratum.


    Second what? Where?

    > After restarting ntpd and waiting some minutes i get this when doing a
    > ntptrace:
    >
    > localhost.localdomain: stratum 6, offset 0.000000, synch distance
    > 0.011279
    >
    > So, basically ntp uses its local clock and then puts a stratum 6 on it.


    What this means is that your ntpd is following the drift of your
    hardware clock.

    > My local clock is sync'ed with a windows2003 server like this:
    >
    > Net time -S x.x.x.x set , and put in crontab.


    You should not be changing the clock while ntpd is running.

    > My 2003 server is sync'ed with the daytime protocol to a internet time
    > server.


    This is probably the worst possible configuration you could have chosen.

    If you must use your Windows 2003 Server as your local time source you
    really should run ntpd on it. There are Windows ports of NTP linked from
    http://ntp.isc.org/links

    > I need a good stratum value because my cisco devices (switches etc)
    > will not sync if the stratum is 16.


    Your ntpd was operating at stratum 16 because, in all likelyhood, it was
    never synchronized to a source of time (i.e. locally attached refclock,
    remote time server).

    > And this works for a 100%!
    > I can see in my cisco device with "show ntp associations"
    >
    > address ref clock st when poll reach delay offset disp
    > *~x.x.x.x 127.127.1.0 6 373 1024 377 3.1 0.28 0.3
    > ~x.x.x.x 127.127.1.0 8 1012 1024 377 2.4 -760.9 103.9


    Only if you consider a 761 milliseconds, or 3/4 of a second, difference
    between your time sources to be acceptable. And if you're not too
    concerned with stability.

    --
    Steve Kostecke
    NTP Public Services Project - http://ntp.isc.org/

+ Reply to Thread