[Mono-list] libpq.so error

Francisco Figueiredo Jr. fxjrlists@yahoo.com.br
Mon, 26 May 2003 16:33:37 -0300

Jonathan Stowe wrote:
> On Mon, 26 May 2003, amerigo5 amerigo5 wrote:
>>I am getting the following error:
>>** (postgres.exe:2407): WARNING **: Failed to load library libpq.so
>>libpq.so: cannot open shared object file: No such file or directory
>>Unhandled Exception: System.MissingMethodException: A missing method
>>exception has occurred.
>>in <0x00046> 06 Mono.Data.PostgreSqlClient.PostgresLibrary:PQconnectdb
>>in <0x000ae> 00 Mono.Data.PostgreSqlClient.PgSqlConnection:Open ()
>>in <0x00052> 00 .Test:Main (string[])
>>Does anyone know what this mean? Thanks.
> Yes, it is likely that you don't have the postgres libraries installed in
> a place that they can be found by applications.  You should check for its
> presence with:
>   locate libpq.so
> This should return the location of the library on your machine.  If it
> doesn't return anything a) you don't have the postgres client libraries
> installed and you will need to install them or b) you haven't run updatedb
> since you installed them.
> If you do get something back from the locate then if the path is not in
> either /usr/lib or /usr/local/lib then you will have to become root
> and edit the file /etc/ld.so.conf to add the directory where the library
> is located.  After you have done that you will need to run /sbin/ldconfig
> to add the libraries in that location to the cache.

You may also want to have a look at Npgsql, another .Net Data Provider 
for Postgresql. More info about it can be found at: 
<http://www.go-mono.com/postgresql.html> and 

I hope it helps.

Francisco Figueiredo Jr.
"My grandfather once told me that there are two kinds of people: those
who work and those who take the credit. He told me to try to be in the
first group; there was less competition there."
- Indira Gandhi