node.js - Mac OS X下如何安装node-oracledb?
PHP中文网
PHP中文网 2017-04-17 13:39:28
[Node.js讨论组]

Mac OS X下如何安装node-oracledb?
错误提示

npm ERR! Darwin 15.4.0
npm ERR! argv "/usr/local/bin/node" "/usr/local/bin/npm" "install" "oracledb"
npm ERR! node v5.7.1
npm ERR! npm  v3.6.0
npm ERR! code ELIFECYCLE

npm ERR! oracledb@1.8.0 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the oracledb@1.8.0 install script 'node-gyp rebuild'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the oracledb package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     node-gyp rebuild
npm ERR! You can get information on how to open an issue for this project with:
npm ERR!     npm bugs oracledb
npm ERR! Or if that isn't available, you can get their info via:
npm ERR!     npm owner ls oracledb
npm ERR! There is likely additional logging output above.
PHP中文网
PHP中文网

认证高级PHP讲师

全部回复(2)
天蓬老师

错误提示很明白,地址https://registry.npmjs.org/node-oracledb不存在,没有node-oracledb这个npm包,确定一下你要安装的模块名到底是什么

PHPz

你检查下所有的错误日志

是不是这下面这端类似文字出现

node-oracledb ERR! Error: Cannot find /opt/oracle/instantclient/libclntsh.dylib
node-oracledb ERR! Error: Do you need to run 'cd /opt/oracle/instantclient && ln -s libclntsh.dylib.* libclntsh.dylib'?
node-oracledb ERR! Error: See https://github.com/oracle/node-oracledb/blob/master/INSTALL.md#instosx

如果有的话,应该就是 Oracle 驱动之类的信息没有配置好。
可以参考这篇文章来安装,OSX 10.10.2 安装编译node-oracle 及 oracle 官方nodejs 驱动 - satanrabbit的个人页面 - 开源中国社区

热门教程
更多>
最新下载
更多>
网站特效
网站源码
网站素材
前端模板
关于我们 免责申明 意见反馈 讲师合作 广告合作 最新更新 English
php中文网:公益在线php培训,帮助PHP学习者快速成长!
关注服务号 技术交流群
PHP中文网订阅号
每天精选资源文章推送
PHP中文网APP
随时随地碎片化学习
PHP中文网抖音号
发现有趣的

Copyright 2014-2025 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号