Installation of MongoDB under 32-bit Linux (CentOS) __linux

Source: Internet
Author: User
Tags mkdir mongodb create database

Download MongoDB

wget http://downloads.mongodb.org/linux/mongodb-linux-i686-2.4.9.tgz

If the above address is not possible to go to the official website download Http://www.mongodb.org/downloads decompression MongoDB

Tar zxvfmongodb-linux-i686-2.4.9.tgz
Create the specified folder and copy the MongoDB past
Mkdir-p/usr/local/mongodb
cp-rmongodb-linux-i686-2.4.9/*/usr/local/mongodb/
Create database storage directory and log storage files
Mkdir-p/data/mongo/data
Touch/data/monogo/dblogs
Start Mongod
/usr/local/mongodb/bin/mongod--dbpath=/data/mongo/data--logpath=/data/mongo/dblogs  --logappend  --fork
//--fork is designed to allow programs to execute backstage
Set up startup
Echo/usr/local/mongodb/bin/mongod--dbpath=/data/mongo/data--logpath=/data/mongo/dblogs--logappend--fork > >/etc/rc.local


To close the Mongod process: Pkill mongod

Start command parameter description:

--dbpath Specify the directory where the database files are stored

--PORT Specifies the port used by the Mongod service default 27017

--fork set the MONGO service to run in the background

--LOGPATH Specifies the directory and file name of the log file

--logappend set each log to add at the end of the file

--journal Enable logging

--PIDFILEPATH specifies the path to the process file, and if not specified, the system will not produce a process

--maxconns Maximum concurrent connection number

--noprealloc to turn off the pre-allocation of data files

--rest Turn off REST API functionality

--nohttpinterface Turn off web management features

--AUTH Specifies that MONGO use the authentication mechanism--BIND_IP bind IP


Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.