Re: [Ntp] Antw: [EXT] Re: New Version Notification for draft‑gruessing‑ntp‑ntpv5‑requirements‑03.txt

Warner Losh <imp@bsdimp.com> Tue, 19 October 2021 14:18 UTC

Return-Path: <wlosh@bsdimp.com>
X-Original-To: ntp@ietfa.amsl.com
Delivered-To: ntp@ietfa.amsl.com
Received: from localhost (localhost [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 6E5E33A08D7 for <ntp@ietfa.amsl.com>; Tue, 19 Oct 2021 07:18:31 -0700 (PDT)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -1.897
X-Spam-Level:
X-Spam-Status: No, score=-1.897 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, HTML_MESSAGE=0.001, SPF_HELO_NONE=0.001, SPF_NONE=0.001] autolearn=ham autolearn_force=no
Authentication-Results: ietfa.amsl.com (amavisd-new); dkim=pass (2048-bit key) header.d=bsdimp-com.20210112.gappssmtp.com
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id bDQmVSCnIatO for <ntp@ietfa.amsl.com>; Tue, 19 Oct 2021 07:18:25 -0700 (PDT)
Received: from mail-vk1-xa2e.google.com (mail-vk1-xa2e.google.com [IPv6:2607:f8b0:4864:20::a2e]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ietfa.amsl.com (Postfix) with ESMTPS id 9FFF33A08D6 for <ntp@ietf.org>; Tue, 19 Oct 2021 07:18:25 -0700 (PDT)
Received: by mail-vk1-xa2e.google.com with SMTP id i6so5033318vkk.5 for <ntp@ietf.org>; Tue, 19 Oct 2021 07:18:25 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20210112.gappssmtp.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=nso/vlavLJ6SNFJnvkUW5ndN0+auZErdD+PTamCsnb0=; b=He8irwFx7pEY7ttHgKFef4PzHi29gc6D/1ixWktHOvinrYmT7e2n7DsY0j6Q1iL8MA oy9Fr8/gHHpE6reomrYs92W3jEVL8RUazLbwUoFA1G+O5B0CwWnhMrSZfhlb21ozA3ZT HlSzH5+qnY+j2KNOUyZeCpVIpvKj5iDmh8rMxtVhxcRQ4GDiPjIpKYYi484RULdiaayE AUSULR+BtDCg9+6RUIG4gsNt6rr6NaxFr+FYMHQlRUHo/bw1Mw3GngyldxVHaDNXcwbq 817tiwVX+CNqXvWJM5E5uEVOuQeukKkOehMBxnPo5ETeob5BLwL6Wm2gGrHoeJFgu+kk VB4w==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=nso/vlavLJ6SNFJnvkUW5ndN0+auZErdD+PTamCsnb0=; b=njuwoBy705MwLWbLpzBgu1K6w0iPJmWqDDUci4sihq9TbhpdkJwsRBOJyJEuz5po4L 1ezmQiq6nb0onZrxk8VK1lc6gEsFELZmiADTurI4H2diLvIkXR4lmr4GOJhkYjplau0n 3CoFaKho6SSrIkyntduXt3+ihYWreRDUOVv73d6v4GqbChMRhxlaxPuYTGqvNX/zZdTa b2WQaKSnp+WjnaZoYpK46484JZIgitDLdRWM+0b8DtM6aQs2Bnrl7AtkzUplSXcdA9Z1 Rwm9osX/1OUC5hdlswUWuBCsCnIjnGFOyHFlKDL9/t+WIloIKt0BEJSXcXvp73YBDHFg 3IDQ==
X-Gm-Message-State: AOAM533NqIyTcFuFmus3U6oeqWsc1+UYJ8Cjnpb2YDFW6YUoAS/DiAdS lNQ48HbQg8wMLkGCNGfYGyvTGvqVTwrVQ+iL/VkywA==
X-Google-Smtp-Source: ABdhPJzFyWmQCqy9xSmVjkglFR+QvFmxULXafFNF4QCKzmFTEdE7UzkXT387pkELi9AYDzzUpVtCW8QhRI9EnMAm+Tw=
X-Received: by 2002:a05:6122:181f:: with SMTP id ay31mr26136021vkb.18.1634653104039; Tue, 19 Oct 2021 07:18:24 -0700 (PDT)
MIME-Version: 1.0
References: <163386015957.12424.6997038478834885480@ietfa.amsl.com> <CAO+dDx=6baLhf9LwSMvR1F0ieuLO6NXmExYLDvcCF2tgchHs8w@mail.gmail.com> <DB8PR02MB5772AC97BFE2D7C1139EFDC0CFB89@DB8PR02MB5772.eurprd02.prod.outlook.com> <E469D9A7-7445-49D9-A8A2-82BA7BF1FA27@gmail.com> <DB8PR02MB57726795E3AD479F0CCFA778CFB99@DB8PR02MB5772.eurprd02.prod.outlook.com> <616D0ADA020000A10004486B@gwsmtp.uni-regensburg.de> <08e60c82-5b4c-5f0f-55e4-206b0d8f18c4@pdmconsulting.net> <CANCZdfqzduC=9oxhqgNJdxUqveRp=WyO+WNXHJTJZ01EO7jTAA@mail.gmail.com> <616E7C50020000A100044925@gwsmtp.uni-regensburg.de>
In-Reply-To: <616E7C50020000A100044925@gwsmtp.uni-regensburg.de>
From: Warner Losh <imp@bsdimp.com>
Date: Tue, 19 Oct 2021 08:18:13 -0600
Message-ID: <CANCZdfrT8TSo9BPZajT=8j4Go81JSryGxJ70Pu7AuEBmfLL3UQ@mail.gmail.com>
To: Ulrich Windl <Ulrich.Windl@rz.uni-regensburg.de>
Cc: Danny Mayer <mayer@pdmconsulting.net>, doug.arnold=40meinberg-usa.com@dmarc.ietf.org, james.ietf@gmail.com, "ntp@ietf.org" <ntp@ietf.org>
Content-Type: multipart/alternative; boundary="00000000000098fe4d05ceb555fd"
Archived-At: <https://mailarchive.ietf.org/arch/msg/ntp/3wNcNcw2bUA9JEM36swtjo1L9x4>
Subject: Re: [Ntp] Antw: [EXT] Re: New Version Notification for draft‑gruessing‑ntp‑ntpv5‑requirements‑03.txt
X-BeenThere: ntp@ietf.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: Network Time Protocol <ntp.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/ntp>, <mailto:ntp-request@ietf.org?subject=unsubscribe>
List-Archive: <https://mailarchive.ietf.org/arch/browse/ntp/>
List-Post: <mailto:ntp@ietf.org>
List-Help: <mailto:ntp-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/ntp>, <mailto:ntp-request@ietf.org?subject=subscribe>
X-List-Received-Date: Tue, 19 Oct 2021 14:18:32 -0000

On Tue, Oct 19, 2021 at 2:05 AM Ulrich Windl <
Ulrich.Windl@rz.uni-regensburg.de> wrote:

> >>> Warner Losh <imp@bsdimp.com> schrieb am 18.10.2021 um 16:54 in
> Nachricht
> <CANCZdfqzduC=9oxhqgNJdxUqveRp=WyO+WNXHJTJZ01EO7jTAA@mail.gmail.com>:
> > On Mon, Oct 18, 2021 at 8:10 AM Danny Mayer <mayer@pdmconsulting.net>
> wrote:
> >
> >>
> >> On 10/18/21 1:49 AM, Ulrich Windl wrote:
> >> >>>> Doug Arnold <doug.arnold=40meinberg-usa.com@dmarc.ietf.org>
> schrieb
> >> am
> >> > 15.10.2021 um 17:53 in Nachricht
> >> > <
> >>
> >
> DB8PR02MB57726795E3AD479F0CCFA778CFB99@DB8PR02MB5772.eurprd02.prod.outlook.co
> > m
> >> >
> >> >
> >> >> Hello James,
> >> >>
> >> >> I agree that leap smearing is a clumsy and dangerous way to avoid the
> >> >> complication of correctly handling leap seconds in distributed
> database
> >> >> software.  And if it was up to me all IT equipment would use TAI for
> all
> >> >> timing except what is displayed to humans.  But it is not up to me.
> The
> >> >> people who are making the call tell me that they believe that leap
> >> seconds
> >> > is
> >> >> less bad than either moving everything from UTC to TAI, or writing
> and
> >> >> debugging database software that manages leap seconds properly.
> >> >>
> >> >> So given that state of affairs.  What do we do?
> >> > Hi!
> >> >
> >> > I guess the standard C library needs new functions to get the correct
> >> time
> >> > first ;-)
> >> > time_t has a problem
> >>
> >
> > Yes. The fundamental problem is that POSIX says there's no such thing
> > as leap seconds in time_t. They don't exist, they don't have a unique
> > encoding. And any way you represent them (there's at least 3 I know
> > of) is ambiguous. This is the reason why smearing is a thing.
> >
> >
> >> > Amazingly gettimeofday can use struct timezone, while clock_gettime()
> >> can't.
> >> > So adding the TAI offset to struct timezone would not help much.
> >>
> >
> > Look at the 'right' timezones.
> >
> > But clock_gettime passes in the 'clock' that you want. You can ask for
> > TAI time, but you still have the ambiguity.
>
> In my version of Linux (rather "new" regarding "industry standards") such
> a flag does not exist.
>

clock_gettime(CLOCK_TAI, &ts);

CLOCK_TAI isn't standardized by POSIX, but it definitely exists in Linux
and has for 15 or 20 years.

Whether or not the system has the requisite information to give it to you
is another matter, but the clock is well defined and absolutely exists.
See Documentation/core-api/timekeeping.rst for its definition.

Warner