Re: Multiple postgresql installations on one machine.

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Charles Tassell <ctassell(at)isn(dot)net>
Cc: Lincoln Yeoh <lyeoh(at)pop(dot)jaring(dot)my>, pgsql-general(at)postgresql(dot)org
Subject: Re: Multiple postgresql installations on one machine.
Date: 2001-10-13 04:03:53
Message-ID: 8112.1002945833@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Charles Tassell <ctassell(at)isn(dot)net> writes:
> I may be wrong, but I don't think it's possible to have them on the same
> port. The problem is that the TCP/IP port defaults to the same as the UNIX
> sockets port, and UNIX sockets are local to the machine, so they are
> completely independent of IP addresses and can not be duplicated.

Unix sockets need to have unique pathnames in the local filesystem.
The PG "port number" is actually only a component of the file name.
So all you need to do if you need to have conflicting port numbers
is to vary the unix_socket_directory parameter for each postmaster.

However, varying the port number is probably a simpler attack...

>> I can't seem to tell psql where to find the moved unix socket.

Use -h /path/to/directory/containing/socket. AFAIR you can set the
path in PGHOST environment variable, if that helps.

regards, tom lane

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Gordan Bobic 2001-10-13 04:20:33 Re: Any Good Way To Do Sync DB's?
Previous Message Bruce Momjian 2001-10-13 03:55:30 Re: phonetic and/or synonym search