MongoDB Start Command mongod parameter description

Source: Internet
Author: User
Tags auth unix domain socket

MongoDB Start Command mongod parameter description
The main parameters of Mongod are:
Basic Configuration
--------------------------------------------------------------------------------

--quiet # quiet Output
--port Arg # Specify the service port number, default ports 27017
--BIND_IP Arg # Bind service IP, if bind 127.0.0.1, can only native access, do not specify default local all IP
--logpath Arg # Specify the MongoDB log file, note that the specified file is not a directory
--logappend # Write a log using append
--pidfilepath Arg # The full path of the PID file, if not set, there are no PID files
--keyfile Arg # The full path of the cluster's private key, valid only for the replica Set schema
--unixsocketprefix Arg # UNIX domain Socket Alternative directory, (default =/tmp)
--fork # run MongoDB as a daemon and create a server process
--auth # Enable Validation
--cpu # Periodic display of CPU utilization and iowait
--dbpath Arg # Specify Database path
--diaglog Arg # Diaglog Options 0=off 1=w 2=r 3=both 7=w+some reads
--directoryperdb # Set each database to be saved in a separate directory
--journal # Enable logging option, MONGODB data operation will be written to the file in the Journal folder
--journaloptions Arg # Enable Log Diagnostics options
--ipv6 # Enable IPV6 option
--jsonp # Allow JSONP form to be accessed via HTTP (with security implications)
--maxconns Arg # Maximum number of simultaneous connections default 2000
--noauth # Do not enable validation
--nohttpinterface # Close the HTTP interface and turn off 27018 port access by default
--noprealloc # Disable data file pre-allocation (often impacting performance)
--noscripting # Disable scripting engine
--notablescan # No table scan allowed
--nounixsocket # Disable UNIX socket snooping
--nssize Arg (=16) # Set the message database. ns File Size (MB)
--objcheck # in the receipt of customer data, check the validity of
--profile Arg # file Parameters 0=off 1=slow, 2=all
--quota # limit the number of files per database, set default to 8
--quotafiles Arg # Number of files Allower per db, requires--quota
--rest # Open a simple rest API
--repair # fix all databases run repair on all DBS
--repairpath Arg # Fix the directory of the files generated by the library, default to directory name DBPath
--slowms Arg (=100) # Value of slow for profile and console log
--smallfiles # Use a smaller default file
--syncdelay Arg (=60) # Number of seconds data written to disk (0=never, not recommended)
--sysinfo # Print some diagnostic system Information
--upgrade # If you need to upgrade your database

* Replicaton Parameters
--------------------------------------------------------------------------------

--fastsync # from a dbpath enabled from the Library Replication service, the DBPath database is a snapshot of the main library and can be used to quickly enable synchronization
--autoresync # If synchronizing data from the library to the main library is much worse, automatic resynchronization
--oplogsize Arg # Set the size of the Oplog (MB)

* Master/slave parameters
--------------------------------------------------------------------------------

--master # Main Library Mode
--slave # from Library mode
--source Arg # from the Library port number
--only Arg # Specify a single database copy
--slavedelay Arg # Set the delay time for synchronizing the main library from the library

* Replica set (replica set) option:
--------------------------------------------------------------------------------

--replset Arg # set Replica set name

* sharding (Shard) option
--------------------------------------------------------------------------------

--configsvr # Declare this is a clustered config service, default port 27019, default directory/data/configdb
--shardsvr # Declare this is a clustered shard, default port 27018
--nomoveparanoia # Turn off paranoid for movechunk data save

# The above parameters can be written in the mongod.conf configuration document for example:
DBPath =/data/mongodb LogPath =/data/mongodb/mongodb.log Logappend = True Port = 27017 Fork = True Auth = True

Source: http://blog.csdn.net/fdipzone/article/details/7442162

MongoDB Start Command mongod parameter description

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.