Mac installation Cx_oracle appears cannot locate an Oracle software error resolution

Source: Internet
Author: User

Refer to this article for the first few steps: http://www.cs.utexas.edu/~mitra/csSpring2011/cs327/cx_mac.html

At the time of the sudo python setup.py build and install

Obviously Echo $ORACLE _home and so on these environment variables are set, but still can not find the ORACLE home error, the error is as follows:

userdemacbook-pro:cx_oracle-5.1.2 mac$ sudo python setup.py buildpassword:traceback (most recent call last):  File " setup.py ", line, in <module>    raise Distutilssetuperror (" cannot locate an Oracle software "distutils.errors . Distutilssetuperror:cannot Locate an Oracle software installationuserdemacbook-pro:cx_oracle-5.1.2 mac$ sudo echo $ Oracle_home/users/mac/oracle/instantclient_11_2

Follow the prompts to find the 132 line of the setup.py file, which is written

119 # Try to determine the Oracle home121 #userOracleHome = Os.environ.get ("Oracle_home") 122 useroraclehome= "/users/ma C/oracle/instantclient_11_2 "123 If Useroraclehome is not none:124     if not Checkoraclehome (useroraclehome):         Messageformat = "Oracle Home (%s) does not refer to" 126                 "9i, 10g or 11g installation." 127         raise Distutilssetuperror (Messageformat% useroraclehome) (else:129 for     path in os.environ["path"]. Split (OS.PATHSEP):         if Checkoraclehome (path): 131             break132     if Oraclehome is none:133         raise Distutilssetuperror ("Cannot locate an Oracle software" 134                 "Installation")

Can not find the directory to play an exception, the program exits, I here in 122 rows to him this directory forced to write dead (to ensure that the directory does exist)

Then in the execution of the installation, the program passes smoothly.

Mac installation Cx_oracle appears cannot locate an Oracle software error resolution

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.