I have Ubuntu 16.04. And reinstall mongobd following tutorial on oficial mongo site - https://docs.mongodb.com/manual/tutorial/install-mongodb-on-ubuntu/ As result i have: mongo -version
MongoDB shell version v4.0.5
git version: 3739429dd92b92d1b0ab120911a23d50bf03c412
OpenSSL version: OpenSSL 1.0.2g 1 Mar 2016
allocator: tcmalloc
modules: none
build environment:
distmod: ubuntu1604
distarch: x86_64
target_arch: x86_64
But I cant start mongodb((
sudo systemctl status mongodb
● mongodb.service - High-performance, schema-free document-oriented database
Loaded: loaded (/etc/systemd/system/mongodb.service; disabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Tue 2019-01-22 16:27:13 UTC; 10s ago
Process: 29736 ExecStart=/usr/bin/mongod --quiet --config /etc/mongod.conf (code=exited, status=1/FAILURE)
Main PID: 29736 (code=exited, status=1/FAILURE)
Jan 22 16:27:13 mahumachinen systemd[1]: Started High-performance, schema-free document-oriented database.
Jan 22 16:27:13 mahumachinen systemd[1]: mongodb.service: Main process exited, code=exited, status=1/FAILURE
Jan 22 16:27:13 mahumachinen systemd[1]: mongodb.service: Unit entered failed state.
Jan 22 16:27:13 mahumachinen systemd[1]: mongodb.service: Failed with result 'exit-code'.
Please help!
mongodb.service
, but if you followed the instructions you linked, the service is actuallymongod.service
. You might be able to figure out the cause of the service failure in/var/log/mongodb/mongod.log
(unless you changed the logging path in/etc/mongod.conf
).