I just downloaded mongodb on my brand new MacBookAir with OS X 10.9.5 by running brew install mongodb .
I tried to run mongod from the terminal and it said no / data / db, so I created it using sudo mkdir /data and sudo mkdir /data/db .
Starting mongod now I get "Unable to create / open lock file: /data/db/mongod.lock errno: 13 Permission denied", but I can work fine with sudo mongod .
How can I make it so that I do not need to run mongod with sudo, but instead just just mongod ?
(I had it on my last computer, but I donβt remember what I did, and this computer went bad.)
source share