12.22 Notes

12.16-12.22 Learning Notes

Mongodb

set up server on AWS EC2

https://docs.mongodb.com/manual/introduction/
https://ianlondon.github.io/blog/mongodb-auth/

securely close mongodb service

use admin
db.shutdownServer()
exit

if not properly closed:
Run
ps -eaf | grep mongod to find the running instance.
If running, kill the process sudo kill <pID> obtained from above grep command.
https://stackoverflow.com/questions/44497009/mongod-error-98-unable-to-lock-file-data-db-mongod-lock-resource-temporarily/44498179

connect to mongodb server

Obtain your MongoDB connection string
https://docs.mongodb.com/manual/reference/connection-string/