在跑步的时候
node -v
它显示以下错误:
node: /usr/lib64/libstdc++.so.6: version `GLIBCXX_3.4.14' not found (required by node)
node: /usr/lib64/libstdc++.so.6: version `GLIBCXX_3.4.18' not found (required by node)
node: /usr/lib64/libstdc++.so.6: version `CXXABI_1.3.5' not found (required by node)
node: /usr/lib64/libstdc++.so.6: version `GLIBCXX_3.4.15' not found (required by node)
node: /lib64/libc.so.6: version `GLIBC_2.17' not found (required by node)
node: /lib64/libc.so.6: version `GLIBC_2.16' not found (required by node)
node: /lib64/libc.so.6: version `GLIBC_2.14' not found (required by node)
答案1
我的错误现已修复,我已经从安装了 nvm这里然后当我跑的时候
nvm -v
问题仍然和我在问题中说的一样
之后这样做堆栈帖子它已修复但是当我退出并运行相同命令时出现相同的错误...所以我按照一些步骤这里我运行以下命令
export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion
尽管我在运行版本更改命令时在某些点上遇到了同样的错误。因此在教完版本后可能会出现问题。然后我运行将默认版本设置为
nvm -ls # to list versions we installed(here also mention default and LTS versions)
nvm alias default 10.5.0
如果没有10.5.0版本,我们应该安装。
nvm install 10.5.0
然后执行上面的导出命令...然后它工作正常