Loading postgresql/bin/pg_recovery +1 −1 Original line number Diff line number Diff line Loading @@ -69,7 +69,7 @@ function recovery () { cd `su postgres -c 'echo $HOME'` # Rsync for sync data cluster su $PG_USER -c "rsync -azvh --progress $PG_DATA/* $PRIMARY_HOST:/$PG_DATA --exclude postmaster.pid --exclude postmaster.opts --exclude pg_log --exclude pg_xlog" su $PG_USER -c "rsync -azvh --delete --progress $PG_DATA/* $PRIMARY_HOST:/$PG_DATA --exclude postmaster.pid --exclude postmaster.opts --exclude pg_log --exclude pg_xlog" # Stop backup psql -U $PG_USER -p $PG_PORT -c "SELECT pg_stop_backup()" Loading Loading
postgresql/bin/pg_recovery +1 −1 Original line number Diff line number Diff line Loading @@ -69,7 +69,7 @@ function recovery () { cd `su postgres -c 'echo $HOME'` # Rsync for sync data cluster su $PG_USER -c "rsync -azvh --progress $PG_DATA/* $PRIMARY_HOST:/$PG_DATA --exclude postmaster.pid --exclude postmaster.opts --exclude pg_log --exclude pg_xlog" su $PG_USER -c "rsync -azvh --delete --progress $PG_DATA/* $PRIMARY_HOST:/$PG_DATA --exclude postmaster.pid --exclude postmaster.opts --exclude pg_log --exclude pg_xlog" # Stop backup psql -U $PG_USER -p $PG_PORT -c "SELECT pg_stop_backup()" Loading