|
|
Problem detection of Cluster DB, and restoration of data base
|
When replication serve detect a problem in Cluster DB, it separates the Cluster
DB from those system .
At this time, a replication server does additional record of the status of Cluster DB into a log file.
Replication server creates a log file (the file name is 'pgreplicate.log') under the directory specified by '-D'
option at the time of starting.
When you find the Cluster DB whose status is 'error' in this log file, please
stop and repair the Cluster DB.
After completing repair of the Cluster DB, you can restart the Cluster DB with
'-R' option .
When you restart the Cluster DB with a '-R' option, after Cluster
DB synchronizes with the data of Master DB, it will be restored to those systems.
(example of Cluster DB restoration)
-------------------------------------------
# su -l postgres
$ /usr/local/pgsql/bin/pg_ctl start -D /usr/local/pgsql/data -o "-i
-R" |
After restoration, since the status of Cluster DB is also recorded into a log
file, you can check the state of Cluster DB at any time.
When you want to add the new Cluster DB, you can add it by the same method as
the above-mentioned 'restoration of DB'.
Access from the outside to Master DB is forbidden until Cluster DB addition processing
is completed, since the additional Cluster DB synchronizes with the data of Master
DB.
When you want to accept a query during Cluster DB addition,
please prepare three or more Cluster DBs.
The query received while locking Master DB is saved in a replication server, and
execute those queries to the Master DB and the Cluster DB after data synchronous
processing end.
Addition of replication server and load balancer
|
A replication server and a load balancer cannot be added dynamically (neither
Cluster DB nor a replication server is stopped).
When you want to add a replication server and a load balancer, please add a server's information to the
configuration file of Cluster DB and a replication server, and reboot (stop + starting ) Cluster DB and a replication server.
|