hadoop-common-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Colin Patrick McCabe (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HADOOP-8806) libhadoop.so: search java.library.path when calling dlopen
Date Fri, 14 Sep 2012 06:55:08 GMT

    [ https://issues.apache.org/jira/browse/HADOOP-8806?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13455613#comment-13455613
] 

Colin Patrick McCabe commented on HADOOP-8806:
----------------------------------------------

Alan, if you have a patch that actually fixes this, maybe you could share it with us?

After doing a little more research, it seems that {{rpath}} is not just for binaries.  Dynamic
libraries can have it too.  Although the man page for {{ld.so}} only mentions it in the context
of executables, it seems like it can embedded into shared libraries as well.  Combine that
with ${ORIGIN}, and at least in theory we could find {{libsnappy.so}} by using the path of
{{libhadoop.so}}.

There's some discussion here: http://stackoverflow.com/questions/6323603/ld-using-rpath-origin-inside-a-shared-library-recursive

It's all a little undocumented and weird, and ${ORIGIN} is definitely Linux- (and maybe Solaris?)
specific, but it might be better than {{LD_LIBRARY_PATH}}.  Maybe.
                
> libhadoop.so: search java.library.path when calling dlopen
> ----------------------------------------------------------
>
>                 Key: HADOOP-8806
>                 URL: https://issues.apache.org/jira/browse/HADOOP-8806
>             Project: Hadoop Common
>          Issue Type: Improvement
>            Reporter: Colin Patrick McCabe
>            Priority: Minor
>
> libhadoop calls {{dlopen}} to load {{libsnappy.so}} and {{libz.so}}.  These libraries
can be bundled in the {{$HADOOP_ROOT/lib/native}} directory.  For example, the {{-Dbundle.snappy}}
build option copies {{libsnappy.so}} to this directory.  However, snappy can't be loaded from
this directory unless {{LD_LIBRARY_PATH}} is set to include this directory.
> Should we also search {{java.library.path}} when loading these libraries?

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message