pg.ddx.io pgsql-admin@postgresql.org mailing list archivehelp / color / mirror / Atom feed
safe to clear pg_xlog archive status directory? 4+ messages / 2 participants [nested] [flat]
* safe to clear pg_xlog archive status directory? @ 2012-12-27 16:49 Burgholzer, Robert (DEQ) <Robert.Burgholzer@deq.virginia.gov> 0 siblings, 1 reply; 4+ messages in thread From: Burgholzer, Robert (DEQ) @ 2012-12-27 16:49 UTC (permalink / raw) To: pgsql-admin I am working through getting a warm standby up and running. I have fumbled a bit, including having a non responsive standby node for a hile, which led (I think) to a big pile of "ready" files in the "pg_xlog/archive_status" directory. My thought is that I need to start fresh, so here is the process that I envision (someone please let me know if I am making mental errors): #1 - turn off archiving on the master, restart #2 - shut down postgresql on the replicant #3 - clear the pg_xlog/archive_status/ dir, with an "rm pg_xlog/archive_status/*" command #4 - perform a fresh rsync backup of my master to my replicant #5 - bring my replicant back up into standby mode #6 - re-enable archiving on the master and restart the postmaster Thanks in advance, r.b. Robert Burgholzer Surface Water Modeler Virginia DEQ Office of Surface and Ground Water Supply 804-869-3066 ^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: safe to clear pg_xlog archive status directory? @ 2012-12-27 17:00 Kris Bushover <kris@spiceworks.com> parent: Burgholzer, Robert (DEQ) <Robert.Burgholzer@deq.virginia.gov> 0 siblings, 1 reply; 4+ messages in thread From: Kris Bushover @ 2012-12-27 17:00 UTC (permalink / raw) To: pgsql-admin Rather than manually syncing the master to the slave, it would be better to use pg_basebackup (http://www.postgresql.org/docs/9.1/static/app-pgbasebackup.html). This will copy the running master to the slave, and assuming the recovery.conf is in place on the slave, it can be restarted into recovery mode almost immediately. From: pgsql-admin-owner@postgresql.org [mailto:pgsql-admin-owner@postgresql.org] On Behalf Of Burgholzer, Robert (DEQ) Sent: Thursday, December 27, 2012 10:49 AM To: pgsql-admin@postgresql.org Subject: [ADMIN] safe to clear pg_xlog archive status directory? I am working through getting a warm standby up and running. I have fumbled a bit, including having a non responsive standby node for a hile, which led (I think) to a big pile of "ready" files in the "pg_xlog/archive_status" directory. My thought is that I need to start fresh, so here is the process that I envision (someone please let me know if I am making mental errors): #1 - turn off archiving on the master, restart #2 - shut down postgresql on the replicant #3 - clear the pg_xlog/archive_status/ dir, with an "rm pg_xlog/archive_status/*" command #4 - perform a fresh rsync backup of my master to my replicant #5 - bring my replicant back up into standby mode #6 - re-enable archiving on the master and restart the postmaster Thanks in advance, r.b. Robert Burgholzer Surface Water Modeler Virginia DEQ Office of Surface and Ground Water Supply 804-869-3066 ^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: safe to clear pg_xlog archive status directory? @ 2012-12-27 17:47 Burgholzer, Robert (DEQ) <Robert.Burgholzer@deq.virginia.gov> parent: Kris Bushover <kris@spiceworks.com> 0 siblings, 1 reply; 4+ messages in thread From: Burgholzer, Robert (DEQ) @ 2012-12-27 17:47 UTC (permalink / raw) To: pgsql-admin Sorry - this was meant for the list: Kris, Thanks for the response and advice. Unfortunately, I am operating on an 8.3 setup, so I do not think that this is available to me. I am trying, of course, to get my head around migrating to the 9.x version, but am a little stuck right now - I need to weather the next month with my current setup (a high data collection period for us) and then tackle the task of upgrading. Does my process, though obviously cumbersome, sound perilous? Thanks again, r.b. From: pgsql-admin-owner@postgresql.org [mailto:pgsql-admin-owner@postgresql.org] On Behalf Of Kris Bushover Sent: Thursday, December 27, 2012 12:01 PM To: pgsql-admin@postgresql.org Subject: Re: [ADMIN] safe to clear pg_xlog archive status directory? Rather than manually syncing the master to the slave, it would be better to use pg_basebackup (http://www.postgresql.org/docs/9.1/static/app-pgbasebackup.html). This will copy the running master to the slave, and assuming the recovery.conf is in place on the slave, it can be restarted into recovery mode almost immediately. From: pgsql-admin-owner@postgresql.org [mailto:pgsql-admin-owner@postgresql.org] On Behalf Of Burgholzer, Robert (DEQ) Sent: Thursday, December 27, 2012 10:49 AM To: pgsql-admin@postgresql.org Subject: [ADMIN] safe to clear pg_xlog archive status directory? I am working through getting a warm standby up and running. I have fumbled a bit, including having a non responsive standby node for a hile, which led (I think) to a big pile of "ready" files in the "pg_xlog/archive_status" directory. My thought is that I need to start fresh, so here is the process that I envision (someone please let me know if I am making mental errors): #1 - turn off archiving on the master, restart #2 - shut down postgresql on the replicant #3 - clear the pg_xlog/archive_status/ dir, with an "rm pg_xlog/archive_status/*" command #4 - perform a fresh rsync backup of my master to my replicant #5 - bring my replicant back up into standby mode #6 - re-enable archiving on the master and restart the postmaster Thanks in advance, r.b. Robert Burgholzer Surface Water Modeler Virginia DEQ Office of Surface and Ground Water Supply 804-869-3066 ^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: safe to clear pg_xlog archive status directory? @ 2012-12-27 22:01 Burgholzer, Robert (DEQ) <Robert.Burgholzer@deq.virginia.gov> parent: Burgholzer, Robert (DEQ) <Robert.Burgholzer@deq.virginia.gov> 0 siblings, 0 replies; 4+ messages in thread From: Burgholzer, Robert (DEQ) @ 2012-12-27 22:01 UTC (permalink / raw) To: pgsql-admin In the interest of follow-up, my process seemed to safely accomplish the goal of resynching my master and replicant in 8.3. Also, I put together a wiki page demonstrating how to verify that the replicant and master are at least on the same page without having to take down the master and raise the replicant. This is something that is nice to do when monitoring these things if you are unsure of the perfection of your configuration: http://sifn.bse.vt.edu/sifnwiki/index.php/Db_warm_standy_verifying Robert Burgholzer Surface Water Modeler Virginia DEQ Office of Surface and Ground Water Supply 804-869-3066 ^ permalink raw reply [nested|flat] 4+ messages in thread
end of thread, other threads:[~2012-12-27 22:01 UTC | newest] Thread overview: 4+ messages (download: mbox mbox.gz follow: Atom feed) -- links below jump to the message on this page -- 2012-12-27 16:49 safe to clear pg_xlog archive status directory? Burgholzer, Robert (DEQ) <Robert.Burgholzer@deq.virginia.gov> 2012-12-27 17:00 ` Kris Bushover <kris@spiceworks.com> 2012-12-27 17:47 ` Burgholzer, Robert (DEQ) <Robert.Burgholzer@deq.virginia.gov> 2012-12-27 22:01 ` Burgholzer, Robert (DEQ) <Robert.Burgholzer@deq.virginia.gov>
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