Re: Solaris strip LD_LIBRARY_PATH when su - oracle

From: joel garry <joel-garry_at_home.com>
Date: Fri, 15 May 2009 09:04:52 -0700 (PDT)
Message-ID: <ee4253a3-90bf-4879-ac82-3a0fa5f7890a_at_f28g2000pra.googlegroups.com>



On May 14, 5:47 pm, johnbhur..._at_sbcglobal.net wrote:
> On May 14, 12:34 pm, KT <kerr.t..._at_gmail.com> wrote:
>
>
>
> > Hi All,
>
> > In my rc script, I have su - oracle to run
> > /var/opt/oracle/product/10.2.0/db_1/bin/lsnrctl
>
> > However, it fails with the following:
> > ld.so.1: /var/opt/oracle/product/10.2.0/db_1/bin/lsnrctl: fatal:
> > libclntsh.so.10.1: open failed: No such file or directory
>
> > The cause is that the env var
> > LD_LIBRARY_PATH=/var/opt/oracle/product/10.2.0/db_1/lib was stripped
> > by the su process. According to the su man page:
> > " Variables with LD_ prefix are removed for security reasons.
> > Thus, su bin will not retain previously exported variables
> > with LD_ prefix while becoming user bin (bin used as example
> > previously)"
>
> > How do I make Solaris 8 su to keep the LD_LIBRARY_PATH setting or hard
> > code this setting into Oracle configuration file so that lsnrctl will
> > not fail?
>
> > Thanks,
> > Kerr
>
> The Oracle install documentation for your release of oracle on the
> correct operating system has complete information about what
> environment variables you need to set and what they should be set to.

Can't say as I find it "complete." It makes assumptions such as everything "works properly." Sometimes it also has "doc bugs," as it appears to be written before the final code is frozen, and later corrections may or may not be timely, or even correct. One little thing off can spin things way out of control.

>
> Please consider following the oracle documentation ... it makes life
> much easier.

That is worth emphasizing. Understanding and a critical eye are also needed, even the best cookbook can't account for a slightly different stove.

jg

--
_at_home.com
Rock'n'Roll Marathon Audit:
http://www3.signonsandiego.com/stories/2009/may/15/1n15marathon001838-rock-n-roll-race-organizers-ret/?uniontrib
Received on Fri May 15 2009 - 11:04:52 CDT

Original text of this message