Skip to main content
  • Subscribe by RSS
  • Ex Libris Knowledge Center

    Perl script oai-pmh.cgi cannot open shared object file

    • Product: Voyager
    • Product Version: 7

    Problem Symptoms

    The following error message appears in the apache log in /m1/shared/httpd/2.x.x/logs/nxxxdb/error.log:

    [debug] OAI-PMH: retrieve_records ListRecords (query: verb=ListRecords&metadataPrefix=marc21)
    [Fri Jun 27 10:04:07 2014] [error] [client xxx.xx.xx.xx] install_driver(Oracle) failed: Can't load '/oracle/app/oracle/product/' for module DBD::Oracle: cannot open shared object file: No such file or directory at /oracle/app/oracle/product/ line 203.
    [Fri Jun 27 10:04:07 2014] [error] [client xxx.xx.xx.xx] at (eval 13) line 3
    [Fri Jun 27 10:04:07 2014] [error] [client xxx.xx.xx.xx] Compilation failed in require at (eval 13) line 3.
    [Fri Jun 27 10:04:07 2014] [error] [client xxx.xx.xx.xx ] Perhaps a required shared library or dll isn't installed where expected
    [Fri Jun 27 10:04:07 2014] [error] [client xxx.xx.xx.xx] at /m1/voyager/csudb/tomcat/vwebv/context/vwebv/htdocs/cgi-bin/oai-pmh.cgi line 646
    [Fri Jun 27 10:04:07 2014] [error] [client xxx.xx.xx.xx] Premature end of script headers: oai-pmh.cgi


    1. Unix libraries are not linked properly.
    2. A different version of Perl is used by Voyager.


    1. Link all *.so* libs from /oracle/app/oracle/product/ to /lib.
    cd $ORACLE_HOME/lib
    for f in `ls ./*.so*`; do;
    sudo ln -s $ORACLE_HOME/lib/$f /lib/$f

    2. Run the following command to provide a soft link to resolve a missing DBD sub-directory in $ORACLE_HOME/perl/lib/site_perl/5.10.0/x86_64-linux-thread-multi/auto:
    ln -s $ORACLE_HOME/perl/lib/site_perl/5.10.0/x86_64-linux-thread-multi/auto/DBD DBD

    3. In oai-pmh.cgi, replaced #!/usr/bin/perl with #!/m1/shared/bin/perl to pick up the correction version of Perl.

    • Article last edited: 08-Aug-2014
    • Was this article helpful?