Difference between revisions of "/etc/mongodb.conf"

From wikieduonline
Jump to navigation Jump to search
Line 13: Line 13:
 
  #port = [[27017]]
 
  #port = [[27017]]
  
<pre>
+
# Enable journaling, http://www.mongodb.org/display/DOCS/Journaling
# Enable journaling, http://www.mongodb.org/display/DOCS/Journaling
+
journal=true
journal=true
+
 
+
# Enables periodic logging of CPU utilization and I/O wait
# Enables periodic logging of CPU utilization and I/O wait
+
#cpu = true
#cpu = true
+
 
+
# Turn on/off security.  Off is currently the default
# Turn on/off security.  Off is currently the default
+
#noauth = true
#noauth = true
+
#auth = true
#auth = true
+
 
+
# Verbose logging output.
# Verbose logging output.
+
#verbose = true
#verbose = true
+
 
+
# Inspect all client data for validity on receipt (useful for
# Inspect all client data for validity on receipt (useful for
+
# developing drivers)
# developing drivers)
+
#objcheck = true
#objcheck = true
+
 
+
# Enable db quota management
# Enable db quota management
+
#quota = true
#quota = true
+
 
+
# Set diagnostic logging level where n is
# Set diagnostic logging level where n is
+
#  0=off (default)
#  0=off (default)
 
 
#  1=W
 
#  1=W
 
#  2=R
 
#  2=R

Revision as of 12:18, 18 February 2022

# mongodb.conf 

# Where to store the data.
dbpath=/var/lib/mongodb

#where to log
logpath=/var/log/mongodb/mongodb.log

logappend=true

bind_ip = 127.0.0.1
#port = 27017
# Enable journaling, http://www.mongodb.org/display/DOCS/Journaling
journal=true

# Enables periodic logging of CPU utilization and I/O wait
#cpu = true

# Turn on/off security.  Off is currently the default
#noauth = true
#auth = true

# Verbose logging output.
#verbose = true

# Inspect all client data for validity on receipt (useful for
# developing drivers)
#objcheck = true

# Enable db quota management
#quota = true

# Set diagnostic logging level where n is
#   0=off (default)
  1. 1=W
  2. 2=R
  3. 3=both
  4. 7=W+some reads
  5. diaglog = 0
  1. Diagnostic/debugging option
  2. nocursors = true
  1. Ignore query hints
  2. nohints = true
  1. Disable the HTTP interface (Defaults to localhost:27018).
  2. nohttpinterface = true
  1. Turns off server-side scripting. This will result in greatly limited
  2. functionality
  3. noscripting = true
  1. Turns off table scans. Any query that would do a table scan fails.
  2. notablescan = true
  1. Disable data file preallocation.
  2. noprealloc = true
  1. Specify .ns file size for new databases.
  2. nssize = <size>
  1. Accout token for Mongo monitoring server.
  2. mms-token = <token>
  1. Server name for Mongo monitoring server.
  2. mms-name = <server-name>
  1. Ping interval for Mongo monitoring server.
  2. mms-interval = <seconds>
  1. Replication Options
  1. in replicated mongo databases, specify here whether this is a slave or master
  2. slave = true
  3. source = master.example.com
  4. Slave only: specify a single database to replicate
  5. only = master.example.com
  6. or
  7. master = true
  8. source = slave.example.com
  1. Address of a server to pair with.
  2. pairwith = <server:port>
  3. Address of arbiter server.
  4. arbiter = <server:port>
  5. Automatically resync if slave data is stale
  6. autoresync
  7. Custom size for replication operation log.
  8. oplogSize = <MB>
  9. Size limit for in-memory storage of op ids.
  10. opIdMem = <bytes>
  1. SSL options
  2. Enable SSL on normal ports
  3. sslOnNormalPorts = true
  4. SSL Key file and password
  5. sslPEMKeyFile = /etc/ssl/mongodb.pem
  6. sslPEMKeyPassword = pass


See also

Advertising: