DBD::Oracle installation causing error

前端 未结 2 1102
逝去的感伤
逝去的感伤 2021-01-29 12:48

I want to connect to an Oracle Database through Perl. For this, I\'m trying to install DBD::Oracle from CPAN by using the following command:

[root@localhost Admi         


        
2条回答
  •  不思量自难忘°
    2021-01-29 13:00

    Refer these steps in given sequence.

    • Install Perl DBI module
    • install below 3 rpm for oracle instant client (from http://www.oracle.com/technetwork/topics/linuxx86-64soft-092277.html)

      oracle-instantclient11.2-basic-11.2.0.3.0-1
      oracle-instantclient11.2-devel-11.2.0.3.0-1
      oracle-instantclient11.2-sqlplus-11.2.0.3.0-1
      

    I am using 64 bit linux box, so choose your RPM accordingly.

    • set below variables:

      LD_LIBRARY_PATH=/usr/lib/oracle/11.2/client64/lib
      ORACLE_HOME=/usr/lib/oracle/11.2/client64
      

      MacOS users will need:

      DYLD_LIBRARY_PATH=/usr/lib/oracle/11.2/client64/
      

      Also add ORACLE_HOME to your PATH variable.

    • download DBD::Oracle from CPAN

    • untar the module and run below commands in given sequence:

      perl Makefile.PL
      make
      make install
      

      OR you can install the module using cpan command

    DONE !!!

提交回复
热议问题