pg.ddx.io  pgsql-docs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Stephen Frost <sfrost@snowman.net>
To: Kristjan Mustkivi <sonicmonkey@gmail.com>
Cc: pgsql-docs@lists.postgresql.org
Subject: Re: pg_basebackup application does not dump all database objects
Date: Fri, 19 May 2023 09:12:56 -0400
Message-ID: <ZGd12D+wYDAMTgU9@tamriel.snowman.net> (raw)
In-Reply-To: <CAOQPKasMoWOkdRSVa43G7ngT6dzAef4a6GptYPqx7X8UHbbovA@mail.gmail.com>
References: <168423776321.714.17805484409630880522@wrigleys.postgresql.org>
	<ZGOP1Tu5bDBkLIdE@tamriel.snowman.net>
	<CAOQPKasMoWOkdRSVa43G7ngT6dzAef4a6GptYPqx7X8UHbbovA@mail.gmail.com>

Greetings,

Please don't top-post on these lists.

* Kristjan Mustkivi (sonicmonkey@gmail.com) wrote:
> Thank you very much for the feedback and a reference! I was under the
> impression that pg_basebackup does everything
> pg_start_backup/pg_stop_backup but with a more user-friendly manner
> and additional steps. But they are then functionally different. For my
> particular case the pg_start_backup/pg_stop_backup approach was better
> as it retained the replication slots as well (the end goal was to move
> the db from old hardware to the new one and have it on the new hw
> exactly as it was on the old one). So I was surprised that
> pg_basebackup did not bring the rep slots along.

pg_basebackup does effectively call pg_start_backup/pg_stop_backup (or
pg_backup_start/pg_backup_stop in newer versions of PG..) and is more
user-friendly and does do the additional steps expected of a low level
backup- and which are documented in the link that I sent you.

Again, it's not enough to just call pg_start_backup and pg_stop_backup
and do a 'cp -a', and that's why pg_basebackup does more than that and
also why we document those other steps for anyone interested in writing
their own backup tool.

Perhaps an argument can be made that replication slots should be
optional for pg_basebackup to include or not (and similarily for other
PG backup tools which use the low-level API).

Thanks,

Stephen

Attachments:

  [application/pgp-signature] signature.asc (832B, ../ZGd12D+wYDAMTgU9@tamriel.snowman.net/2-signature.asc)
  download

view thread (5+ messages)  latest in thread

Message-ID: <ZGd12D+wYDAMTgU9@tamriel.snowman.net>
Permalink:  ../ZGd12D+wYDAMTgU9@tamriel.snowman.net/
Also on:    postgresql.org/message-id/ZGd12D+wYDAMTgU9@tamriel.snowman.net

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-docs@postgresql.org
  Cc: sfrost@snowman.net, sonicmonkey@gmail.com, pgsql-docs@lists.postgresql.org
  Subject: Re: pg_basebackup application does not dump all database objects
  In-Reply-To: <ZGd12D+wYDAMTgU9@tamriel.snowman.net>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox