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, then only native access, do not specify default local all IP
--logpath arg# Specifies the MongoDB log file, note that the specified file is not a directory
--logappend# Write a log using an Append method
--pidfilepath Arg# The full path of the PID file, if not set, there are no PID files
--keyfile Arg# The full path of the private key of the cluster, valid only for the replica Set schema
--unixsocketprefix arg# UNIX domain socket replacement directory (default =/tmp)
--fork# running MongoDB as a daemon, creating a server process
--auth# Enable validation
--CPU# Periodically displays CPU utilization and iowait for CPUs
--dbpath arg# Specifies the database path
--diaglog arg# diaglog option 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 operations will be written to the files in the Journal folder
--journaloptions arg# Enable log diagnostics option
--ipv6# enable IPV6 option
--jsonp# allows JSONP form to be accessed via HTTP (with security implications)
--maxconns arg# maximum simultaneous connections default of 2000
--noauth# do not enable validation
--nohttpinterface# Turn off HTTP interface, turn off 27018 port access by default
--noprealloc# Disabling data file pre-allocation (often impacting performance)
--noscripting# Disabling the scripting engine
--notablescan# do not allow table scans
--nounixsocket# Disabling 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 parameter 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# repair all databases run repair on all DBS
--repairpath arg# Fix directory of files generated by the library, default to directory name DBPath
--slowms Arg (=100)# Value of slow for profile and console log
--smallfiles# using 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 the database * Replicaton parameter
--------------------------------------------------------------------------------
--fastsync# from a dbpath to enable the Copy service from the library, 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# Setting the size of Oplog (MB) * Master/slave parameters
--------------------------------------------------------------------------------
--master# Main Library mode
--slave# from Library mode
--source Arg# from the library port number
--only arg# Specifies a single database copy
--slavedelay arg# Sets 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# declares that this is a clustered shard, the 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
This article is from "Ghost" blog, please make sure to keep this source http://caizi.blog.51cto.com/5234706/1543538
MongoDB Start Command mongod parameter description