psql question

Started by Jefim Matskinover 24 years ago2 messagesgeneral
Jump to latest
#1Jefim Matskin
mjefim@sphera.com

I have an instance of postgres sql 7.1.2 running with unix socket located in
other directory than default (-k option of the postmaster).
How can I tell the psql utility to connect to that socket?

Jefim

#2Command Prompt, Inc.
pgsql-general@commandprompt.com
In reply to: Jefim Matskin (#1)
Re: psql question

On Sun, 4 Nov 2001, Jefim Matskin wrote:

I have an instance of postgres sql 7.1.2 running with unix socket located in
other directory than default (-k option of the postmaster).
How can I tell the psql utility to connect to that socket?

Use the -h flag. When prefixed with a slash, it refers to a local
directory for the socket, rather than a host. E.g.:

[root@dev lxp]# psql -h /tmp template1
Welcome to psql, the PostgreSQL interactive terminal.
[...]

Regards,
Jw.
--
jlx@commandprompt.com
by way of pgsql-general@commandprompt.com