Unable to create/open lock file: /data/mongod.lock errno:13 Permission denied

前端 未结 28 1566
执念已碎
执念已碎 2020-11-29 14:39

How to I get mongo to use a mounted drive on ec2? I really do not understand. I attached a volume on ec2 formatted the drive as root and start as root and yet as root I ca

28条回答
  •  遥遥无期
    2020-11-29 15:11

    If you literally want a one line equivalent to the commands in your original question, you could alias:

    mongo --eval "db.getSiblingDB('admin').shutdownServer()"
    

    https://stackoverflow.com/a/11777141/7160782

提交回复
热议问题