Pgpool - 3.5 configuration
you need to set up backend PostgreSQL servers for pgpool-II. These servers can be placed within the same host as pgpool-II, or on separate machines. If you decide to place the servers on the same host, different port numbers must be assigned for each server. If the servers are placed on separate machines, they must be configured properly so that they can accept network connections from pgpool-II.

if you will place two servers within the same host as pgpool-II, let's  suppose that you want to assign 5432, 5433 port numbers respectively. To configure pgpool-II, edit pgpool.conf as follows.

backend_hostname0 = 'localhost'
backend_port0 = 5432
backend_weight0 = 1
backend_hostname1 = 'localhost'
backend_port1 = 5433
backend_weight1 = 1


For backend_hostname, backend_port, backend_weight, set the node's hostname, port number, and ratio for load balancing. At the end of each parameter string, node ID must be specified by adding positive integers starting with 0 (i.e. 0, 1, 2, …).

backend_weight parameters are all 1, meaning that SELECT queries are equally distributed Between two servers.

Starting/Stopping pgpool

$pgpool


The above command, however, prints no log messages because pgpool detaches the terminal. If you want to show pgpool log messages, you pass -n option to pgpool command so pgpool-II is executed as non-daemon process, and the terminal will not be detached.

$ pgpool -n &amp;


The log messages are printed on the terminal, so the recommended options to use the following.

$ pgpool -n -d &gt; /tmp/pgpool.log 2&gt;&amp;1 &amp;


The -d option enables debug messages to be generated.

To stop pgpool, execute the following command.

$ pgpool stop


If any client is still connected, pgpool waits for it to disconnect, and then terminates itself. Run the following command instead if you want to shutdown pgpool forcibly.

$ pgpool -m fast stop


For further your ref Here