, когда я пытаюсь запустить 'sudo service mongo start', тогда вывод: 'Не удалось запустить mongod.service: Unit mongod.service не найден.'
вывод mongo is -:
x2@jj2:~$ mongo
MongoDB shell version: 3.0.15
connecting to: test
2017-07-24T12:59:56.386+0530 W NETWORK Failed to connect to 127.0.0.1:27017, in(checking socket for error after poll), reason: errno:111 Connection refused
2017-07-24T12:59:56.388+0530 E QUERY Error: couldn't connect to server 127.0.0.1:27017 (127.0.0.1), connection attempt failed
at connect (src/mongo/shell/mongo.js:179:14)
at (connect):1:6 at src/mongo/shell/mongo.js:179
exception: connect failed
, а статус: -
x2@jj2:~$ sudo service mongodb status
● mongodb.service - High-performance, schema-free document-oriented database
Loaded: loaded (/etc/systemd/system/mongodb.service; enabled; vendor preset:
Active: failed (Result: exit-code) since Mon 2017-07-24 13:06:05 IST; 9min ag
Process: 29210 ExecStart=/usr/bin/mongod --quiet --config /etc/mongod.conf (co
Main PID: 29210 (code=exited, status=1/FAILURE)
Jul 24 13:06:05 x2 systemd[1]: Started High-performance, schema-free docu
Jul 24 13:06:05 x2 systemd[1]: mongodb.service: Main process exited, code
Jul 24 13:06:05 x2 systemd[1]: mongodb.service: Unit entered failed state
Jul 24 13:06:05 x2 systemd[1]: mongodb.service: Failed with result 'exit-
У вас есть:
Active: failed (Result: exit-code) since Mon 2017-07-24 13:06:05 IST; 9min ag
Failed означает, что вы не выполняете:
Failed to connect to 127.0.0.1:27017...
попробуйте запустить:
sudo service mongodb restart
У вас есть:
Active: failed (Result: exit-code) since Mon 2017-07-24 13:06:05 IST; 9min ag
Failed означает, что вы не выполняете:
Failed to connect to 127.0.0.1:27017...
попробуйте запустить:
sudo service mongodb restart