Re: Proposal: Add backup start time to pg_stat_progress_basebackup

From: Rob Moore <robmoore121(at)gmail(dot)com>
To: "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>
Cc: "pgsql-hackers(at)lists(dot)postgresql(dot)org" <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: Proposal: Add backup start time to pg_stat_progress_basebackup
Date: 2026-01-20 03:46:23
Message-ID: CAEGgwttFOGU3xa=ZpomGudZHtkM291TmKw1HLaVYqwZaaJNJfQ@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Thanks David, I've just tried this, and joining to pg_stat_activity on pid
works great. I'll do that.

Sorry for the noise 😅,
Rob

On Tue, Jan 20, 2026 at 11:22 AM David G. Johnston <
david(dot)g(dot)johnston(at)gmail(dot)com> wrote:

> On Monday, January 19, 2026, Rob Moore <robmoore121(at)gmail(dot)com> wrote:
>>
>>
>> Was backup start time intentionally omitted
>> from pg_stat_progress_basebackup, or would it be okay for me or someone
>> else to add it as a column? Or, am I being daft and there is another
>> obvious way to get the start time for an in-progress base backup?
>>
>>
> Not sure about base backup but the other progress reporting commands would
> get that info from pg_stat_activity.query_start which can be joined to
> using pid. backend_start is likely close enough for pg_basebackup if it
> doesn’t recognize the replication protocol as a “command”. I haven’t
> checked.
>
> David J.
>
>
>

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message jinbinge 2026-01-20 03:50:33 A minor grammar error was found in a comment in the smgrtruncate function
Previous Message Chao Li 2026-01-20 03:45:50 Re: tablecmds: clarify recurse vs recusing