From: Amir Rohan <amir.rohan@mail.com>
To: Jeff Janes <jeff.janes@gmail.com>
Cc: Pg Bugs <pgsql-bugs@postgresql.org>
Subject: Re: BUG #13642: no backup_label file in PG_DATA after pg_stop_backup();
Date: Sat, 26 Sep 2015 09:27:50 +0300
Message-ID: <56063AE6.9060407@mail.com> (raw)
In-Reply-To: <CAMkU=1wGQ3nNu8bKJpwtjCjnNUAzAT=nyp4kFXDDk6XfDJL8kg@mail.gmail.com>
References: <20150926031617.3022.6412@wrigleys.postgresql.org>
<CAMkU=1wGQ3nNu8bKJpwtjCjnNUAzAT=nyp4kFXDDk6XfDJL8kg@mail.gmail.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-bugs>
On 09/26/2015 06:30 AM, Jeff Janes wrote:
> On Fri, Sep 25, 2015 at 8:16 PM, <amir.rohan@mail.com
> <mailto:amir.rohan@mail.com>> wrote:
>
> Doesn't create the `backup_label` described in the docs (I'm assuming
> "cluster directory" means data directory, e.g. $PGDATA):
> http://www.postgresql.org/docs/current/static/continuous-archiving.html
>
>
>
> Is backup_label present in your *backup*? That is where it is needed.
> It is not needed in $PGDATA itself. It is created in $PGDATA simply so
> that a copy of it gets included in your backup.
>
> Cheers,
>
> Jeff
No. Well, there's a backup file in the archive directory that looks like
it might be /it/ but it's not named `backup_label` (it wouldn't, since
multiple backups need to coexist).
As mentioned earlier, in the backup procedure docs:
| pg_start_backup creates a backup label file, called backup_label, in |
the cluster directory with information about your backup, including
| the start time and label string. The file is critical to the
| integrity of the backup, should you need to restore from it.
About 8 paragraphs below (where only the brave have stamina to keep
reading):
| It's also worth noting that the pg_start_backup function makes a file
| named backup_label in the database cluster directory, which is
| removed by pg_stop_backup [Ok, I missed that]. This file will
| of course be archived as a part of your backup dump file <...>
But:
- There's no single "backup dump file" that the file is "part of"
(creating a .tgz isn't part of the workflow described). It's
just a sequence of one or more WAL files.
- It doesn't mentioned that the file gets renamed.
The section previous (on using pg_basebackup not sql commands) talks
about something different called a "backup history file", I guess
a "backup_label" becomes one, one PG knows what xlog the backup ends at.
This isn't great documentation. I'll send a patch to pgsql-docs with
suggested improvements.
Thanks for the help,
Amir
--
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs
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 from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-bugs@postgresql.org
Cc: amir.rohan@mail.com, jeff.janes@gmail.com
Subject: Re: BUG #13642: no backup_label file in PG_DATA after pg_stop_backup();
In-Reply-To: <56063AE6.9060407@mail.com>
References: <20150926031617.3022.6412@wrigleys.postgresql.org> <CAMkU=1wGQ3nNu8bKJpwtjCjnNUAzAT=nyp4kFXDDk6XfDJL8kg@mail.gmail.com> <56063AE6.9060407@mail.com>
* 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