我正在尝试使用Robo3T查看我的本地主机数据库,但没有任何运气。我的解析实例位于localhost:1337/parse
在新的终端标签中先运行mongod
,然后运行mongo
,会为我提供以下信息:
-> mongod
2018-08-06T17:17:53.268-0400 I CONTROL [initandlisten] MongoDB starting : pid=31906 port=27017 dbpath=/data/db 64-bit host=Zacks-MacBook-Pro.local
2018-08-06T17:17:53.269-0400 I CONTROL [initandlisten] db version v3.6.4
2018-08-06T17:17:53.269-0400 I CONTROL [initandlisten] git version: d0181a711f7e7f39e60b5aeb1dc7097bf6ae5856
2018-08-06T17:17:53.269-0400 I CONTROL [initandlisten] OpenSSL version: OpenSSL 1.0.2o 27 Mar 2018
2018-08-06T17:17:53.269-0400 I CONTROL [initandlisten] allocator: system
2018-08-06T17:17:53.269-0400 I CONTROL [initandlisten] modules: none
2018-08-06T17:17:53.269-0400 I CONTROL [initandlisten] build environment:
2018-08-06T17:17:53.269-0400 I CONTROL [initandlisten] distarch: x86_64
2018-08-06T17:17:53.269-0400 I CONTROL [initandlisten] target_arch: x86_64
2018-08-06T17:17:53.269-0400 I CONTROL [initandlisten] options: {}
2018-08-06T17:17:53.272-0400 I STORAGE [initandlisten] exception in initAndListen: IllegalOperation: Attempted to create a lock file on a read-only directory: /data/db, terminating
2018-08-06T17:17:53.273-0400 I CONTROL [initandlisten] now exiting
2018-08-06T17:17:53.273-0400 I CONTROL [initandlisten] shutting down with code:100
~
-> mongo
MongoDB shell version v3.6.4
connecting to: mongodb://127.0.0.1:27017
2018-08-06T17:18:03.892-0400 W NETWORK [thread1] Failed to connect to 127.0.0.1:27017, in(checking socket for error after poll), reason: Connection refused
2018-08-06T17:18:03.894-0400 E QUERY [thread1] Error: couldn't connect to server 127.0.0.1:27017, connection attempt failed :
connect@src/mongo/shell/mongo.js:251:13
@(connect):1:6
exception: connect failed
尝试连接localhost:27017
和localhost:1337
都没有运气。还不确定数据库名称/登录名/密码是什么,因为它是本地主机。
任何帮助将不胜感激