mongodb服务未运行。设置的哪一部分是错误的?

时间:2019-06-20 06:19:03

标签: mongodb ubuntu-16.04 config

我如下所示启动了mongodb service,但输入时没有任何反应。 我也检查状态,但失败了。
我看不到哪一部分错了。你能帮我吗?

j@location:~$ sudo service mongodb start
j@location:~$ sudo service mongodb status
● mongodb.service - High-performance, schema-free document-oriented database
   Loaded: loaded (/etc/systemd/system/mongodb.service; enabled; vendor preset: enabled)
   Active: failed (Result: exit-code) since Thu 2019-06-20 15:20:03 KST; 7s ago
  Process: 13405 ExecStart=/usr/bin/mongod --quiet --config /etc/mongod.conf (code=exited, status=1/FAILURE)
 Main PID: 13405 (code=exited, status=1/FAILURE)

Jun 20 15:20:03 location systemd[1]: Started High-performance, schema-free document-oriented database.
Jun 20 15:20:03 location systemd[1]: mongodb.service: Main process exited, code=exited, status=1/FAILURE
Jun 20 15:20:03 location systemd[1]: mongodb.service: Unit entered failed state.
Jun 20 15:20:03 location systemd[1]: mongodb.service: Failed with result 'exit-code'.
hanadmin@location:~$

还要附加mongodb.conf设置。

  2 # for documentation of all options, see:
  3 #   http://docs.mongodb.org/manual/reference/configuration-options/
  4
  5 # Where and how to store data.
  6 storage:
  7   dbPath: /var/lib/mongodb
  8   journal:
  9     enabled: true
 10 #  engine:
 11 #  mmapv1:
 12 #  wiredTiger:
 13
 14 # where to write logging data.
 15 systemLog:
 16   destination: file
 17   logAppend: true
 18   path: /var/log/mongodb/mongod.log
 19
 20 # network interfaces
 21 net:
 22   port: 27017
 23   bindIp: [127.0.0.1,10.0.0.1,8.8.8.8,0.0.0.0]
 24
 25
 26 #processManagement:
 27
 28 #security:
 29
 30 #operationProfiling:
 31
 32 #replication:
 33
 34 #sharding:
 35
 36 ## Enterprise-Only Options:

0 个答案:

没有答案