Issues accessing MongoDB remotely

Hi @Shrikar_Man,

Yes, you can run directly type mongo in the shell and run the MongoDB without any command-line options to connect to a MongoDB instance running on your localhost with default port 27017.

mongo

You can also use mongo to run the MongoDB on a specific port if you want.!!

mongo --port 28015

So, you don’t need to run mongod explicitly but you can use the mongod command with the mongod.conf file to run your specific custom configuration on your machine.!!

In case of any further questions, please feel free to reach out to us.

Thanks,
Kushagra