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
Refer these steps in given sequence.
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 !!!
Thanks for the info! I noticed that oracle-instantclient12.1-devel-12.1.0.2.0-1.x86_64.rpm installed into /usr. So adding a soft link like this helps me solved the problem.
sudo ln -s /usr/include/oracle/11.2/client64 $ORACLE_HOME/include