2012年10月4日 星期四

Install MongoDB and Node.js on CentOS 6.2

Mongo DB:
Note: must create folder /data/db (it's Mongo DB default folder)
1. background job:
Please read link on below:
http://docs.mongodb.org/manual/tutorial/install-mongodb-on-redhat-centos-or-fedora-linux/

2. foreground job:
 (1)download Mongo DB .tar files on your local computer.
 (2)create folder and set permissons
      "$ mkdir -p /data/db"
      "$chown -R $USER:$USER /data/db"
(3)extract .tar file
     "$tar zxf mongodb-linux-XXXXX.tar.gz"
     "$cd mongodb-linux-XXXXX"
(4)start Mongo DB now
     "$ bin/mongod"
 
Node.js:
1.use yum
wget http://nodejs.tchol.org/repocfg/el/nodejs-stable-release.noarch.rpm
yum localinstall --nogpgcheck nodejs-stable-release.noarch.rpm
yum install nodejs-compat-symlinks npm
rm nodejs-stable-release.noarch.rpm


沒有留言: