Skip site navigation (1) Skip section navigation (2)

Re: connecting with libpq interface

From: Markus Wanner <markus(at)bluegap(dot)ch>
To: Vincent Predoehl <vpredoehl(at)phoenixwebgroup(dot)com>
Cc: pgsql-interfaces(at)postgresql(dot)org
Subject: Re: connecting with libpq interface
Date: 2008-07-13 15:56:10
Message-ID: 487A259A.9090803@bluegap.ch (view raw or flat)
Thread:
Lists: pgsql-interfaces
Hi,

Vincent Predoehl wrote:
>>> terminate called after throwing an instance of 'pqxx::broken_connection'
>>>    what():  could not connect to server: No such file or directory
>>>          Is the server running locally and accepting
>>>          connections on Unix domain socket "/var/run/
>>> postgresql/.s.PGSQL.5432"?
>>
>> PQerrorMessage() should give you the same info in your standalone
>> libpq program.
> 
> Yes it does:
> 
> could not connect to server: No such file or directory
>         Is the server running locally and accepting
>         connections on Unix domain socket 
> "/var/run/postgresql/.s.PGSQL.5432"?

Something similar has biten me before as well. I figured it is the 
Debian packager's decision to put those socket files under 
/var/run/postgresql/, which is not the Postgres standard.

Regards

Markus


In response to

pgsql-interfaces by date

Next:From: Sunil KhatriDate: 2008-07-22 15:41:13
Subject: PQstatus is not returning
Previous:From: Alvaro HerreraDate: 2008-07-11 21:48:47
Subject: Re: connecting with libpq interface

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group