CentOS 7 使用 npm 失败 npm: symbol SSL_set_cert_cb
使用yum源直接安装node.js
yum -y install nodejs
将其换成国内源的时候,发生异常:
异常信息
[root@VM_58_62_centos ~]# npm install -g cnpm --registry=https://registry.npm.taobao.org
npm: relocation error: npm: symbol SSL_set_cert_cb, version libssl.so.10 not defined in file libssl.so.10 with link time reference
[root@VM_58_62_centos ~]#

解决方案
安装yum工具包
yum -y install yum-utils
安装或更新openssl
yum -y install openssl
yum -y update openssl
启用
yum-config-manager --enable cr
yum update

网友评论