In addition to the advice that Ramachandra provided, if mongod
had been started by root
it’s highly probable that the data and log files/directories are also owned by the root
user. You will need to check those as well and change the ownership of those before mongod
will run as your normal user.