Productive Linux


 Subscribe via Feedburner in a reader

Enter your email address:

Delivered by FeedBurner


Don't have an account?
Sign up to
Forgot your password?

Postgresql - multiple installs
9 April 2012 @ 15:33 BST
by Paul

When installing postgresql be aware that if you have several server instances on the same machine, then postgresql will manage the ports on which each server listens by itself.

From the Debian README:

Please note that the pg_* tools automatically manage the server ports unless you specify them manually. The first cluster which is ever created (by any major version) will run on the default port 5432, and each new cluster will use the next higher free one.
Please use "pg_lsclusters" for displaying the cluster <-> port mapping, and please have a look at the pg_createcluster manpage (the --port option) for details.

The output from pg_lsclusters will look something like this:

Version Cluster   Port Status Owner    Data directory                     Log file
8.2     main      5432 down   postgres /var/lib/postgresql/8.2/main       /var/log/postgresql/postgresql-8.2-main.log
8.4     main      5433 online postgres /var/lib/postgresql/8.4/main       /var/log/postgresql/postgresql-8.4-main.log
Tags: postgresql

Comments disabled