I'm trying to install nodejs on Centos 6.8 using these instrcutions:
http://tecadmin.net/install-latest-nodejs-and-npm-on-centos/#
When I run
yum install nodejs
But I get the following errors
Resolving Dependencies
--> Running transaction check
---> Package nodejs.x86_64 0:5.12.0-1nodesource.el7.centos will be installed
--> Processing Dependency: libstdc++.so.6(GLIBCXX_3.4.15)(64bit) for package: nodejs-5.12.0-1nodesource.el7.centos.x86_64
--> Processing Dependency: libc.so.6(GLIBC_2.15)(64bit) for package: nodejs-5.12.0-1nodesource.el7.centos.x86_64
--> Finished Dependency Resolution
Error: Package: nodejs-5.12.0-1nodesource.el7.centos.x86_64 (nodesource)
Requires: libstdc++.so.6(GLIBCXX_3.4.15)(64bit)
Error: Package: nodejs-5.12.0-1nodesource.el7.centos.x86_64 (nodesource)
Requires: libc.so.6(GLIBC_2.15)(64bit)
You could try using --skip-broken to work around the problem
You could try running: rpm -Va --nofiles --nodigest
First, we'll use npm, nodes' module manager, to install express middleware and supervisor - a helpful module that keeps our app started, monitors for file changes (ie.
Best way to install nodejs (latest version) on centos 7: (Make sure you are a sudo user)
cd ~
wget http://nodejs.org/dist/v10.15.1/node-v10.15.1-linux-x64.tar.gz
(Must check the latest version change the version name accordingly)sudo tar --strip-components 1 -xzvf node-v10.15.1-linux-x64.tar.gz -C /usr/local
(Must check the latest version change the version name accordingly) node --version
Try it before install:
yum clean all
rm -rf /var/cache/yum/*
yum update
my problem was in cached packages ...
Maybe you'll need to install gcc-c++ and make before install nodejs using yum.
Try this:
$ yum install -y gcc-c++ make
$ curl -sL https://rpm.nodesource.com/setup_6.x | sudo -E bash -
And then:
$ yum install nodejs
And confirm it using:
$ node -v
http://tecadmin.net/install-latest-nodejs-and-npm-on-centos/
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With