Re: Clock-skew management in logical replication

From: Nisha Moond <nisha(dot)moond412(at)gmail(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>, Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>, Shveta Malik <shveta(dot)malik(at)gmail(dot)com>, "Hayato Kuroda (Fujitsu)" <kuroda(dot)hayato(at)fujitsu(dot)com>, Dilip Kumar <dilipbalaut(at)gmail(dot)com>, "Zhijie Hou (Fujitsu)" <houzj(dot)fnst(at)fujitsu(dot)com>, tomas(at)vondra(dot)me
Subject: Re: Clock-skew management in logical replication
Date: 2024-09-25 02:50:19
Message-ID: CABdArM64ntCX8P5Bb32OxQX86mS+o33D-za0gyLSw1PNACkd-w@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Mon, Sep 23, 2024 at 4:00 PM Nisha Moond <nisha(dot)moond412(at)gmail(dot)com> wrote:
>
> On Fri, Sep 20, 2024 at 7:51 PM Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> >
> > Nisha Moond <nisha(dot)moond412(at)gmail(dot)com> writes:
> > > While considering the implementation of timestamp-based conflict
> > > resolution (last_update_wins) in logical replication (see [1]), there
> > > was a feedback at [2] and the discussion on whether or not to manage
> > > clock-skew at database level.
> >
> > FWIW, I cannot see why we would do anything beyond suggesting that
> > people run NTP. That's standard anyway on the vast majority of
> > machines these days. Why would we add complexity that we have
> > to maintain (and document) in order to cater to somebody not doing
> > that?
> >
> > regards, tom lane
>
> Thank you for your response.
>
> I agree with suggesting users to run NTP and we can recommend it in
> the docs rather than introducing additional complexities.
>
> In my research on setting up NTP servers on Linux, I found that
> Chrony[1] is a lightweight and efficient solution for time
> synchronization across nodes. Another reliable option is the classic
> NTP daemon (ntpd)[2], which is also easy to configure and maintain.
> Both Chrony and ntpd can be used to configure a local machine as an
> NTP server for localized time synchronization, or as clients syncing
> from public NTP servers such as 'ntp.ubuntu.com' (default ntp server
> pool for Ubuntu systems) or 'time.google.com'(Google Public NTP).
> For example, on Ubuntu, Chrony is straightforward to install and
> configure[3]. Comprehensive NTP(ntpd) configuration guides are
> available for various Linux distributions, such as Ubuntu[4] and
> RedHat-Linux[5].
>
> Further, I’m exploring options for implementing NTP on Windows systems.
>

Windows platforms provide built-in time synchronization services. As a
client, they allow users to sync system time using internet or public
NTP servers. This can be easily configured by selecting a public NTP
server directly in the Date and Time settings. More details can be
found at [1].

Additionally, Windows servers can be configured as NTP servers for
localized time synchronization within a network, allowing other nodes
to sync with them. Further instructions on configuring an NTP server
on Windows can be found at [2].

[1] https://learn.microsoft.com/en-us/windows-server/networking/windows-time-service/how-the-windows-time-service-works
[2] https://learn.microsoft.com/en-us/troubleshoot/windows-server/active-directory/configure-authoritative-time-server

Thanks,
Nisha

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Noah Misch 2024-09-25 03:03:45 Re: Primary and standby setting cross-checks
Previous Message Noah Misch 2024-09-25 02:00:22 Re: AIO writes vs hint bits vs checksums