Nodejs install on centos7

This article demonstrates how to install Nodejs on CentOS7.

1 Ready to work#

1.1 Browser access installation package download address:

https://nodejs.org/dist/

Find the version that needs to be installed. Take version 8.11.3 as an example. The address is:

https://nodejs.org/dist/v8.11.3/node-v8.11.3.tar.gz

1.2 Download source code###

$ mkdir -p /usr/local/nodejs
$ wget  https://nodejs.org/dist/v8.11.3/node-v8.11.3.tar.gz
$ tar -zxvf node-v8.11.3.tar.gz -C /usr/local/nodejs

2 installation#

2.1 Install dependent packages###

$ yum -y install gcc gcc-c++ kernel-devel

2.2 Compile and install###

$ cd /usr/local/nodejs/node-v8.11.3
$ ./configure
$ make
$ make install

2.3 Check the installation###

Execute the above instructions in sequence. The make process may take a little longer. After the instructions are executed, Node is installed. You can use node -v and npm -v to check whether the installation is successful.

3 Update#

nodejs can use the n module to update:

3.1 Install n module###

$ npm install -g n 

3.2 Upgrade nodejs to the latest stable version###

$ n stable

3.3 Update nodejs to the specified version###

$ n 8.11.3

Recommended Posts

Nodejs install on centos7
Install Node.js on Centos
CentOS install nodejs 8
Install Docker on Centos7
install LNMP on centos7.4
Install Java on Centos 7
Install FFmpeg on CentOS 8
Install RabbitMQ on CentOS 7
Install nodejs10 on Ubuntu16
CentOS6.8 install node.js npm
Maven install on centos7
Install MongoDB on CentOS 7
Install Surelog on CentOS8
Openjdk install on centos7
Install Jenkins on centos7
install RabbitMQ on centos
Install RabbitMQ on CentOS 7
install Docker on centos6.5
install oracle on centos
Install Elasticsearch 6 on centos7
Install RabbitMQ on CentOS7
Install mysql online on centos
Install MySQL 8.0.16 on Linux Centos
Install docker transfer on Centos7
How to install Node.js and npm on CentOS 8
Install docker on Centos system
install EPEL repo on centos
1.5 Install Centos7
Install Zabbix 3.4 based on CentOS 7
install virtualbox on centos server
Install Nginx server on CentOS 7
How to install jdk1.8 on centOS7
How to install MySQL on CentOS 8
Install JDK8 in rpm on CentOS7
How to install Memcached on CentOS 8
Install MATE or XFCE on CentOS 7
How to install R on CentOS 8
How to install Virtualbox on CentOS 8
How to install TensorFlow on CentOS 8
How to install TeamViewer on CentOS 8
How to install Perl 5 on CentOS
How to install Git on CentOS 8
How to install Gradle on CentOS 8
How to install Elasticsearch on CentOS 8
How to install Jenkins on CentOS 8
How to install Java on CentOS 8
How to install Go on CentOS 8
How to install GCC on CentOS 8
How to install Yarn on CentOS 8
How to install Nginx on CentOS 8
How to install Asterisk on CentOS 7
How to install Jenkins on CentOS 8
Install MySQL on Linux CentOS7 (Windows)
How to install Vagrant on CentOS 8
How to install Python 3.8 on CentOS 8
How to install Tomcat 9 on CentOS 8
How to install Webmin on CentOS 8
How to install Ruby on CentOS 8
How to install Skype on CentOS 8
How to install htop on CentOS 8
​Install Oracle database on CentOS Linux