Re: Remote connection via psql - Mailing list pgsql-general

From Tom Lane
Subject Re: Remote connection via psql
Date
Msg-id 4386.1031151633@sss.pgh.pa.us
Whole thread Raw
In response to Re: Remote connection via psql  (Francois Suter <dba@paragraf.ch>)
List pgsql-general
Francois Suter <dba@paragraf.ch> writes:
>> Francois Suter <dba@paragraf.ch> writes:
> psql -d dbname -U username -h 192.168.1.2
> I get the following message: "psql: unknown host name: 192.168.1.2"
>>
>> Works fine here.  What PG version is this, what platform, etc?

> PG version is 7.2.1, platform is Mac OS X 10.1.5, network uses a router that
> serves as a DHCP server, but the dev server mentioned here as a fixed IP
> (i.e. 192.168.1.2).

OS X eh?  I seem to recall a prior thread about that, in which it
emerged that the gethostbyname() routine is kinda broken on OSX.
Everywhere else it will accept a numeric IP, but not on OSX --- unless
you send the query to a nameserver.  Or something like that; I think
the guy did find a workaround.  Check the list archives.

            regards, tom lane

pgsql-general by date:

Previous
From: Francois Suter
Date:
Subject: Re: Remote connection via psql
Next
From: Greg Copeland
Date:
Subject: Archives DB is down?