Posts

Showing posts from October, 2017

How to reset mongodb rootadmin password ??

Image
Sometimes we have to manage credentials for lots of things and its obvious that we can forget one of them. Here I am going to explain that how we can reset "rootadmin" password for running mongodb replica set. I am not going in details about installation, configuration or functionality detail. Instead, I'll directly jump to actual technical hacking stuff. Along with with we'll also learn some sed tricks that can be handy on many occasions. Things responsible for Authentication/Permissions with in mongodb replica set- security:   keyFile: "/data/mongo3.2/node3/mongo_3.2-keyfile"   authorization: "enabled" keyFile - This is the path to file that stores the shared secret that all MongoDB instances use to authenticate to each other in a sharded cluster or replica set. authorization - This will Enable or disable Role-Based Access Control (RBAC) to govern each user’s access to database resources and operations. By default, this wil...