32位centos6.9 安装nodejs+mysql环境

  • Post author:
  • Post category:mysql


由于更换了一个32位的linux系统云服务器(便宜 :-)),重新安装环境的时候踩了不少坑。最开始是照着网上通过命令 wget https://nodejs.org/dist/v12.13.0/node-v12.13.0-linux-x64.tar.xz 来下载压缩包来直接部署,结果出现 cannot execute binary file 错误,这是因为32位的系统不能安装64位的nodejs, 可是官网上又没有32位的编译包,这可怎么办呢。之后我又尝试使用yum,   首先指定版本:curl –silent –location https://rpm.nodesource.com/setup_12.x | bash –  ,结果又报错Your distribution, identified as “centos-release-6-9.el6.12.3.i686”, is not currently supported…意思就是不支持你这个操作系统。。

万万没想到,最后我还是安装成功了。完整记录如下:

安装gcc/c++/g++,用于编译

wget http://people.centos.org/tru/devtools-2/devtools-2.repo
mv devtools-2.repo /etc/yum.repos.d
yum install devtoolset-2-gcc devtoolset-2-binutils devtoolset-2-gcc-c++
ln -s /opt/rh/devtoolset-2/root/usr/bin/gcc /usr/bin/gcc
ln -s /opt/rh/devtoolset-2/root/usr/bin/c++ /usr/bin/c++
ln -s /opt/rh/devtoolset-2/root/usr/bin/g++ /usr/bin/g++
</



版权声明:本文为qq_36368991原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。