Re: 8.3 to 8.4 - Can't load dynamic shared library

From: Craig James <craig_james(at)emolecules(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-admin(at)postgresql(dot)org
Subject: Re: 8.3 to 8.4 - Can't load dynamic shared library
Date: 2010-07-15 20:39:37
Message-ID: 4C3F7209.4060908@emolecules.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

On 7/15/10 12:52 PM, Tom Lane wrote:
> Craig James<craig_james(at)emolecules(dot)com> writes:
>> On the Postgres 8.3 system, I simply put libopenbabel.so into the /usr/local/pgsql/lib directory, and everything worked well. On 8.4, I can't seem to get it to load libopenbabel.so. Other programs that use this library have no trouble finding it.
>
>> What (if anything) has changed from 8.3 to 8.4 regarding how it finds
> and links dynamic libraries?
>
> Nothing. I think this more likely is a consequence of your platform
> switch from Fedora to Ubuntu. I'm not sure how the dynamic linker's
> search path is defined on Ubuntu, but it might be different. Or
> possibly it's the same but you forgot about making an /etc/ld.so.conf.d
> entry on the new machine, or didn't run ldconfig afterwards.

We don't use /etc/ld.so.conf.d, and never have.

On 8.3.10 and earlier, Postgres would ONLY load this library if we put it in /usr/local/pgsql/lib, so I figured it was a security restriction, that Postgres altered the LD_LIBRARY_PATH to ensure that only legitimate, admin-approved libraries could be loaded. The Postgres documentation sort of hints at this but doesn't give details.

Is this true, that Postgres restricts the dynamic linker in some way? And if so, is there documentation?

Craig

In response to

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message dx k9 2010-07-15 20:48:31 Re: tablespaces
Previous Message Tom Lane 2010-07-15 19:52:15 Re: 8.3 to 8.4 - Can't load dynamic shared library