On Mon, Dec 13, 2010 at 5:01 PM, Heikki Linnakangas <heikki.linnakan...@enterprisedb.com> wrote: > If the only consequence is that you get some extra WAL files in the archive, > until pg_archivecleanup runs again, I think we can just live with it.
We might get some extra WAL files also in pg_xlog. Because the WAL files which don't have .ready/.done file survive two checkpoints after failover. IOW, though first checkpoint right after failover should remove those WAL files, they cannot be removed since they don't have .done file. Then the first checkpoint creates .ready files for them, the archiver performs bulk-archiving (this would be harm in performance if there are many such WAL files), and the subsequent checkpoint removes them. > But > don't you have bigger problems when standby tries to archive a file that > already exists in the archive, because master already archived it? We advise > to write archive_command so that it fails if the file exists already. Yep, that's recommended in the document, but I don't want to use that. Because that might make new master fail to archive WAL file because of existence of half-baked file in the archive, after failover. This can happen if the master crashes while its archiver is copying WAL file. Regards, -- Fujii Masao NIPPON TELEGRAPH AND TELEPHONE CORPORATION NTT Open Source Software Center -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers