Also known as Rserv

The eR server is the enterprise Replication Server for PostgreSQL. To obtain the eR server, go to the web site at www.pgsql.com. Or check in the directory path /usr/local/src/postgresql-7.1.2/contrib/ for the rserv/ folder, which holds all of the source files.

Note Note
 

If you downloaded the eR server from the Internet, then it is important that you decompress the zipped file in the contrib/ directory beneath PostgreSQL 7.1. Once the eR server is made, it begins looking for the PostgreSQL source files. If you did not install PostgreSQL 7.1 in /usr/local/src/, then you can move the compressed file to the contrib/ directory beneath where you installed PostgreSQL.

Listed below are the required components to make replication possible between a master and slave machine:

  • Two copies of the Replication server. One copy is on the master machine and the other copy is on the slave machine. You may have to repeat the steps on obtaining the eR server if these machines do not have a copy of the replication server.

  • Both the master and slave machine should have PostgreSQL 7.1 running on it.

  • Perl's Pg module. This is needed to run the MasterInit file. Refer to the sub-heading on installing the Pg module for instructions.

We will refer to the path /usr/local/src/postgresql-7.1.2/contrib/ as the location which holds the eR server. You can also substitute your database name into the places where we use the booktown database.

Step 1:Unpacking the Source

If you are using the existing files in your contrib/ directory, then you can skip this step. On the other hand, if you downloaded the eR server from the Internet, you will need to use the following command to unpack the eR server:

  • tar xzvf rserv-0.1-pg7.1.tar

Step 2:Installing the eR server

After the last command has finished execution, a new directory named rserv/ was automatically created. Move to that directory:

   cd rserv/
   

You will now need to make the files. Depending on your system, you can either use the make or gmake command :

   gmake
   

Note BSD users
 

In BSD, gmake is called gnumake.

After the make has finished, continue to make the installation files by using the command:

   gmake install
   

If you do not have the Pg module installed on both the master and slave machine, then you should walk through the steps to install the Pg module. If you have the Pg module installed, you are now ready to configure the eR server. You should skip to the section entitled Configuring the eR server. It will walk you through the main steps needed to use a replication server.