Launching mongod instance with requirements

How do I specify the requirements when I launch mongod?

Hi Ben,

Not sure if I understand your question.

  • If you are talking about how to specify requirements in a config file, here is the sample config file:
storage:
  dbPath: /var/lib/mongodb
  journal:
    enabled: true

systemLog:
  destination: file
  logAppend: true
  path: /var/log/mongodb/mongod.log

net:
  port: 27017
  bindIp: 127.0.0.1

To run mongod, mongod -f mongod_conf.yaml [ or you can use --config as well ]

Detail documentation can be found here

Kanika

What Im asking is, how exactly do I create the actual file. I know what to put in it. I know how to create a file in terminal with “touch” but how to I write this code into this file from terminal since the file is not actually on my local machine and therefore doesnt appear in finder. This process is not explained at all