Sometimes it happens that you reach a point where you know that things cannot be any easier than they already are.
Table of Contents
I think in PostgreSQL 9.3 we will pretty much have reached this point when we fire up a simple replica. Back in the old times you had to call pg_start_backup
, rsync the entire stuff, call pg_stop_backup
and finally come up with a recovery.conf
file to setup a single standby.
Things have changed and some time ago pg_basebackup
made life so much easier. No more rsync (in the typical case), no more function calls. But still, a normal user had to come up with a simple recovery.conf
file to control the recovery process.
However, when you take a look at pg_basebackup
, you'll figure out that the call itself already has all info a user will typically need to write a simple recovery.conf
file. So, why not use this info and write a recovery.conf
file straight away if desired?
This is exactly what Zoltan has implemented for 9.3:
The patch just got committed recently http://git.postgresql.org/pg/commitdiff/915a29a10cdabfbe301dc7201299841339b9798f
All you have to do is to call pg_basebackup
with the "-R" option. A simple recovery.conf
file will be written automatically. The only thing left to do now is to fire up your brand new standby (pg_ctl start ...).
I guess there is no way to make it any easier.
Read more:
pg_basebackup: Creating self-sufficient backups
PostgreSQL: Bulk loading huge amounts of data
+43 (0) 2622 93022-0
office@cybertec.at
You are currently viewing a placeholder content from Facebook. To access the actual content, click the button below. Please note that doing so will share data with third-party providers.
More InformationYou are currently viewing a placeholder content from X. To access the actual content, click the button below. Please note that doing so will share data with third-party providers.
More Information