This section covers installation and configuration of the SIOS Protection Suite and PostgreSQL software when adding LifeKeeper to an existing PostgreSQL configuration. The Primary server is assumed to be the location of the active PostgreSQL database cluster that will be protected. These steps assume the database cluster to be protected is the version created by the default installation of PostgreSQL (e.g. postgresql-x64-9.6 with PostgreSQL v9.6) These steps below must be followed in order.
- Install the SIOS Protection Suite software on the Primary and Backup Server.
- Using the LifeKeeper GUI on the Primary Server, create comm paths between the primary and backup server.
On the Primary Server:
Use the Disk Management utility to configure your disk resources and define the shared or replicated volumes that you want to use. Be sure the volume size is adequate. If you are configuring shared volumes, power down the backup server during configuration to avoid simultaneous access to your storage.
It is recommended that you use Windows Explorer to unshare all volumes to be used by the PostgreSQL Server Instance from the network.
Configure your networking to support the SIOS Protection Suite TCP/IP comm path(s) and the switchable IP address if applicable.
On the Backup Server:
Start the backup server if it was stopped to configure shared volumes in Step 3.
Use the Disk Management utility to configure your disk resources and define the shared or replicated volumes that you want to use. If you are using shared storage, assign the same drive letter to the shared volume as assigned on the primary server. For replicated storage be sure the volume size is adequate.
On the Primary Server:
In SIOS Protection Suite, create your shared or replicated Volume resource (where the PostgreSQL database cluster will reside) and extend it to the backup server. Later when you create your PostgreSQL Server resource hierarchy. SIOS Protection Suite will automatically bring the resource into the hierarchy as a dependency.
On the Backup Server:
Bring the volume resource hierarchy In Service using the LifeKeeper GUI.
Install PostgreSQL to the same program folder as it is installed to on the primary server using the following guidelines:
Using the —extract-only argument to the PostgreSQL installer is not recommend as it does not configure all of the information required by the PostgreSQL Recovery Kit.
By default the installation of the PostgreSQL software creates a single database cluster (a database cluster is a collection of databases that is managed by a single instance of a running PostgreSQL database server). During installation the Data Directory prompt determines where the database cluster will be created. The default instance can be installed at any location since it will be deleted in step 6d.
The default database cluster instance created during installation is not required and can be removed.
Stop the database cluster instance created during installation.
Open Explorer and access the drive associated with the replicated volume.
Delete the PostgreSQL database cluster directory created during the installation.
Delete the PostgreSQL service that was created during installation. You can use the Windows “sc delete “ command to do this.
On the Primary Server:
Bring the volume resource hierarchy In Service using the LifeKeeper GUI.
Stop the PostgreSQL database cluster instance that is to be protected by the PostgreSQL Recovery Kit.
Optional – Perform a backup of the PostgreSQL database cluster data directory prior to moving it to the protected volume created above.
Move the database cluster data directory to the protected volume created above.
Set the access rights on the database cluster data directory. The user account setup to control the Window’s Service for this instance must have full control file permissions on the data directory.
Follow the steps outlined in Configuring the Postmaster Port Argument on the primary server. The configuration should also include modification of –D argument which specifies the location of the data directory. It should be changed to the path on the protected volume.
Follow the steps outlined in Configure for Unattended Connections on the primary server.
When the installation and configuration is complete, start the Windows PostgreSQL service to verify that the PostgreSQL Server can start properly on the primary server with the Postmaster port argument and the data directory now located on the protected volume.
Create the PostgreSQL Server hierarchy on the primary server and extend it to the backup server. See Creating the PostgreSQL Hierarchy for more information. Test the new PostgreSQL Server hierarchy by performing a manual switchover.
Post your comment on this topic.