Re: Postgres 9.6 Streaming Replication on Solaris 10

From: John R Pierce <pierce(at)hogranch(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: Postgres 9.6 Streaming Replication on Solaris 10
Date: 2016-12-21 19:46:56
Message-ID: 4c835852-7c6f-11a5-ba3e-cb6b72ec73d3@hogranch.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 12/19/2016 8:15 PM, rich(at)salepointdata(dot)com wrote:
> Yes it is set in both the user's .profile and also in
> /etc/profile. In both files it is set using:
> LD_LIBRARY_PATH=/usr/sfw/lib:/usr/postgres/9.6-pgdg/lib
> export LD_LIBRARY_PATH
>
> That said, if I execute the following
> su password
> su postgres
> echo $LD_LIBRARY_PATH
>
> then echo returns blank. Echo will return the correct value only in
> the usr login. The question then is if postgres is running as usr
> postgres how does it know the value of LD_LIBRARY_PATH. Isn't there
> another place where it must be set?
>

environment variables, including LD_LIBRARY_PATH gets dropped by su,
which is used to launch the postgres service.

but generally, using LD_LIBRARY_PATH is frowned on, instead, you should
link the applications with -R, or -Wl,-rpath and give it the path of the
libraries, so thats baked into the binary.

--
john r pierce, recycling bits in santa cruz

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Guillaume Lelarge 2016-12-21 20:59:24 Re: pg_restore to a port where nobody is listening?
Previous Message Daniel Westermann 2016-12-21 19:29:20 Re: pg_restore to a port where nobody is listening?