[R] Mysteriously vanishing LD_LIBRARY_PATH

Marc Schwartz marc_schwartz at me.com
Thu Jul 9 04:40:58 CEST 2009


On Jul 8, 2009, at 8:45 PM, p_connolly at slingshot.co.nz wrote:

> Using R-2.8.0 and R-2.8.1, I get behaviour like this:
>
> R version 2.8.0 (2008-10-20)
> Copyright (C) 2008 The R Foundation for Statistical Computing
> ISBN 3-900051-07-0
>
> [....]
>
>> Sys.getenv("LD_LIBRARY_PATH")
>
>          LD_LIBRARY_PATH
> "/home/hrapgc/local/R-2.8.0/lib:/usr/local/lib:/usr/lib/gcj-4.1.1:/ 
> home/hrapgc/Rstuff/library/asreml/libs"
>> q()
> Save workspace image? [y/n/c]: n
>
>
> However:
>
> R version 2.9.1 (2009-06-26)
> Copyright (C) 2009 The R Foundation for Statistical Computing
> ISBN 3-900051-07-0
>
> [...]
>
>> Sys.getenv("LD_LIBRARY_PATH")
>                                                   LD_LIBRARY_PATH
> "/home/hrapgc/local/R-2.9.1/lib:/usr/local/lib:/usr/lib/gcj-4.1.2"
>
>
> I'm particularly dismayed by the fact that there are now only three
> parts to LD_LIBRARY_PATH, and slightly mystified by the appearance of
> /usr/lib/gcj-4.1.2 in place of /usr/lib/gcj-4.1.1.  Maybe that's a red
> herring since the former is a link to the latter.
>
> I would appreciate help getting the rest of LD_LIBRARY_PATH back.  I
> set it in ~/.bash_profile in case that makes a difference to the
> possible cause of the phenomenon.
>
> $ uname -r
> 2.6.18-92.1.22.el5
>
> The problem doesn't seem to arise with Fedora 8 nor with Mepis 6.5.
>
> TIA

Patrick,

When I was using Fedora, several years ago I started to add any paths  
that I needed for LD_LIBRARY_PATH into /etc/ld.so.conf. Then run 'sudo  
ldconfig' to update the configuration.

I got bit by the same issue that you are seeing when using RODBC with  
Oracle. I believe that it was Prof. Ripley who suggested that I use  
the above approach and did not have any problems after that.

HTH,

Marc Schwartz




More information about the R-help mailing list