Environment: CentOS Release 6.7 (Final)
Linux tomcat_4 2.6.32-573.el6.x86_64 #1 SMP Thu Jul 15:44:03 UTC x86_64 x86_64 x86_64 gnu/linux
wget http://people.centos.org/tru/devtools-2/devtools-2.repo-O/etc/yum.repos.d/devtools-2.repo
Yum Install-y devtoolset-2-gcc devtoolset-2-binutils devtoolset-2-gcc-c++
#需要注意的是: If you use NPM to install the error, you can check the GCC version, If the GCC version is 4.4, you need to perform the following command to change GCC to 4.8 to use NPM to install related modules
SCL enable devtoolset-2 bash
wget https:// nodejs.org/dist/v4.2.1/node-v4.2.1.tar.gz
Tar-xvzf node-v4.2.1.tar.gz
CD node-v4.2.1
./configure - -prefix=/usr/local/node.js
Make && make install
#注意oracle客户端必须装Version 12.1.0.1.0 or more, If version 11 is installed, the CPU will 100%
Nodejs install the Oracle module when the NODEJS connects to the database, please refer to the URL, using RPM and zip two ways
https://github.com/oracle/ NODE-ORACLEDB/BLOB/MASTER/INSTALL.MD
If you are installing using a ZIP file, add the following lines to the. Bash_profile in the user directory, and note the path to the Oracle client
Export oci_lib_dir=/opt/oracle/instantclient_12_1/
Export oci_inc_dir=/opt/oracle/instantclient_12_1/sdk/ include/
Export ld_library_path=/opt/oracle/instantclient_12_1/: $LD _library_path
Install node. js