python 2.6 cx oracle,python   install cx_Oracle

1.安装python

linux 自带安装了python2.6.6

2.安装easy_install

按照官网说明,无法安装

[root@server3 backup]# wget https://bootstrap.pypa.io/ez_setup.py -O - | python

--2014-09-05 16:59:01--  https://bootstrap.pypa.io/ez_setup.py

正在解析主机 bootstrap.pypa.io... 103.245.222.175

正在连接 bootstrap.pypa.io|103.245.222.175|:443... 已连接。

错误: 证书通用名 “*.c.ssl.fastly.net” 与所要求的主机名 “bootstrap.pypa.io” 不符。

要以不安全的方式连接至 bootstrap.pypa.io,使用‘--no-check-certificate’。

依照提示 用 --no-check-certificate 下载ez_setup.py

[root@server3 backup]# wget https://bootstrap.pypa.io/ez_setup.py --no-check-certificate

然后 python ez_setup.py 安装

3. 安装cx_Oracle

[root@server3 backup]# easy_install cx_Oracle

Searching for cx-Oracle

Reading https://pypi.python.org/simple/cx_Oracle/

Reading http://cx-oracle.sourceforge.net

Reading http://starship.python.net/crew/atuining

Best match: cx-Oracle 5.1.3

Downloading https://pypi.python.org/packages/source/c/cx_Oracle/cx_Oracle-5.1.3.tar.gz#md5=cd6ff16559cbc9c20087ec812c7092ab

Processing cx_Oracle-5.1.3.tar.gz

Writing /tmp/easy_install-qNEdPX/cx_Oracle-5.1.3/setup.cfg

Running cx_Oracle-5.1.3/setup.py -q bdist_egg --dist-dir /tmp/easy_install-qNEdPX/cx_Oracle-5.1.3/egg-dist-tmp-7rg1rD

error: cannot locate an Oracle software installation

依照提示,设定好 oracle相关环境

export ORACLE_HOME=/oracle/oracle/product/11.2.3

export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:$ORACLE_HOME/lib

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值