如何在Mac上安装Oracle Instant Client? [英] How to install Oracle Instant Client on a Mac?
问题描述
如何在Mac(OS X 10.11.5)上安装Oracle Instant Client版本12.1.0.2(64位)
How to install Oracle Instant Client Version 12.1.0.2 (64-bit) on a Mac (OS X 10.11.5)
我已经下载了12.1.0.2版(64位)版本并解压缩了文件.
I have downloaded version 12.1.0.2 (64-bit) version and unzipped the file.
我现在在/downloads/instantclient下有以下文件:
I now have the following files under /downloads/instantclient:
libclntsh.dylib.12.1
libclntshcore.dylib.12.1
libnnz12.dylib
libocci.dylib.12.1
libociei.dylib
libocijdbc12.dylib
libons.dylib
liboramysql12.dylib
ojdbc6.jar
ojdbc7.jar
uidrvci
xstreams.jar
adrci
BASIC_README
genezi
我丝毫不知道如何从此版本过渡到Instant Client的有效版本,因此我可以从CLI连接到数据库. Oracle网站上的说明似乎过于复杂.
I don't have the slightest idea how to go from this to a working version of Instant Client so I can connect to a db from the CLI. The instructions on Oracles website seem to be overly complicated.
我发现了一些博客,详细介绍了安装方法,但它们似乎都来自Instant Client的早期版本.出于绝望,我下载了早期版本的Instant Client,但似乎仍然缺少本教程中提到的文件.
I have found a few blogs detailing the installation method, but they all seem to be from previous version of Instant Client. Out of desperation, I downloaded a previous version of Instant Client, but still seemed to be missing files referred to in the tutorial.
有人知道如何在Mac上获得Oracle Instant Client吗?
Does anyone know how I can get Oracle Instant Client on my Mac?
推荐答案
HomeBrew救了我.我不知道环境路径.
HomeBrew saved me. I do not figure out the environment path.
1.从以下位置下载以下两个文件: http://www.oracle .com/technetwork/topics/intel-macsoft-096467.html .
由于Oracle许可证,这是必需的.
This is necessary because of Oracle licenses.
instantclient-basic-macos.x64–11.2.0.4.0.zip
和
instantclient-sqlplus-macos.x64–11.2.0.4.0.zip
将文件放入~/Library/Caches/Homebrew
PS:
在最新版本的HomeBrew中,将替换为 ~/Library/Caches/HomeBrew/downloads
.
in the latest versions of HomeBrew replace the above location
~/Library/Caches/HomeBrew
with~/Library/Caches/HomeBrew/downloads
.
并使用HomeBrew建议的名称重命名下载的文件.
And also rename the downloaded files with the names suggested by HomeBrew.
感谢@manuka_m
Thanks to @manuka_m
2.接下来运行以下命令
$ brew tap InstantClientTap/instantclient
$ brew tap InstantClientTap/instantclient
$ brew install Instantclient-basic
$ brew install instantclient-basic
$ brew install Instantclient-sqlplus
$ brew install instantclient-sqlplus
这篇关于如何在Mac上安装Oracle Instant Client?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!