On Fri, Nov 4, 2016 at 7:04 PM, Venkata B Nagothi <nag1...@gmail.com> wrote: > Sure. I will look at the possibility of using XLOG_BACKUP_END in my patch. > I am looking at the possibility of keeping the backup_label at source until > pg_stop_backup() > is executed and then write the STOP information and then move it across to > the backup location.
Non-exclusive backups already do that, except that as the backup is already stopped at the moment the backup_label information is sent back to the caller, and it is expected that it will be the caller that will write its contents into the backed up PGDATA in a file named as backup_label. Anyway, any design in this area for exclusive backups would be really inconsistent. For example take the case of pg_start_backup -> cp -> pg_stop_backup for an exclusive backup, when are you going to update the backup_label file with the stop info? > I see that when the START/STOP information is written to the WAL history > file, > the content from the backup_label file is being copied and I am thinking to > do the same other way around. > > Am i making sense ? is that anyway not possible ? > > If this makes sense, then i would start working on an optimal design and > look at the possibility of achieving this. Before writing any code, I would be curious about the need behind that, and you give no reason where this would help in this thread. Do you actually want to time the timestamp when backup ends? This could be added as a new field of pg_stop_backup for both the exclusive and non-exclusive cases. Just an idea. -- Michael -- Sent via pgsql-hackers mailing list (firstname.lastname@example.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers