Restore database
Restore database
От:
Alexander Burbello <alexander@cresoltec.com.br>
Дата:
I need to test and create a procedure to restore databases.
I followed the steps based on the site, but I couldn't finish succesfully.
I did:
1. Put the database on Backup Mode and copy datafiles.
/pg/bin/psql cresoldev -c "SELECT pg_start_backup('/pg/backup/');"
tar -cvf /pg/backup/bk_base.tar /pg/data/base/*
/pg/bin/psql cresoldev -c "SELECT pg_stop_backup();"
File .conf: archive_command = 'cp -i %p /pg/backup/xlog/%f