Search Postgresql Archives

Re: Does PostgreSQL check database integrity at startup?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




Em 26/12/2017 15:13, Alvaro Herrera escreveu:
Edson Carlos Ericksson Richter wrote:

I'm rebuilding the standby server for two days already, with 23% of
completion status...
So how do you build your standbys, exactly?  Maybe there's a bug in your
procedure, rather than a bug in the software.

Usually, or by "pg_basebackup" or by "rsync" as described in PostgreSQL Wiki.
Right now, I'm doing via pg_basebackup.
Nothing extraordinary.

When using rsync:

rsync -e "ssh -2 -C -p slave_ssh_port" --progress --partial -az /pgsql/9.6/master_data_folder/* superuser_name@$slave_host:/home/pgsql/9.6/slave_data_folder/ --exclude postmaster.pid --exclude postgresql.conf --exclude pg_log

When using pg_basebackup:

/usr/pgsql-9.6/bin/pg_basebackup -h master_host -p master_port -D /home/pgsql/9.6/master_data_folder -R -S slot_name -X stream -P -d " user=superuser_name password=superuser_pass sslmode=require "


Of course, this is inside a bash script with variables at right places to make script generic as needed to make it works with dozens of databases...

Regards,

Edson




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]

  Powered by Linux