Skip to content

MongoDB Configuration (Deprecated)

Sowmya Balasubramanian edited this page Nov 4, 2020 · 1 revision

Configuring and Running MongoDB:

Config file: /etc/mongod.conf For CentOS, RedHat or Fedora, use the instructions found here: http://docs.mongodb.org/manual/tutorial/install-mongodb-on-redhat-centos-or-fedora-linux/

For other flavors, find the instructions for your distribution here: http://docs.mongodb.org/manual/installation/#installation-guides

If you are modifying the port and url, then make a note of it. You will need it when you configure the Lookup Service.

  1. Logging
    If you want to have logRotation set
    logRotate: rename
    Mongodb does not initiate logRotation. To force MongoDB to rotate the logs, add a crontab to send a SIGUSR1 signal to mongod process
    kill -s USR1 `cat /var/run/mongodb/mongod.pid `

For more information, refer: http://docs.mongodb.org/manual/reference/configuration-options/