Environment of this configuration: centos6.5 64-bit
Required Files :
Instantclient-basic-linux-x86-64-11.2.0.2.0.zip
Instantclient-sdk-linux-x86-64-11.2.0.2.0.zip
Cx_oracle-5.1.2.tar.gz
I put these three papers in/home/hadoop/oracle.
Code implementation:
SU root input password switch to root user cd/home/hadoop/oracleunzip Instantclient-basic-linux-x86-64-11.2.0.2.0.zipunzip Instantclient-sdk-linux-x86-64-11.2.0.2.0.zip unzip the directory to generate instantclient_11_2 file CD instantclient_11_2ln-s libclntsh.so.11.1 Libclntsh.socd. Tar zxvf cx_oracle-5.1.2.tar.gzcd cx_oracle-5.1.2python setup.py Install the appropriate package: Yum install gcc Libffi-devel Python-devel openssl-develvim/etc/profile Add cx_oracle Path Export oracle_home=/home/hadoop/oracle/instantclient_11_ 2export ld_library_path= $LD _library_path: $ORACLE _homesource/etc/profile here cx_oracle installation Complete test: Import cx_ Oracle Note Oracle's O is uppercase, wish you well
This article is from the "10700016" blog, please be sure to keep this source http://10710016.blog.51cto.com/10700016/1881429
Installation of Cx_oracle source under CentOS installation 64-bit