Failed to start mongod.service: Unit mongod.service not found.
$ sudo nano /etc/systemd/system/mongodb.service
[Unit]
Description=High-performance, schema-free document-oriented database
After=network.target
[Service]
User=mongodb
ExecStart=/usr/bin/mongod --quiet --config /etc/mongod.conf
[Install]
WantedBy=multi-user.target
-
Now you can start the service and check its state by
$ sudo systemctl start mongodb $ sudo systemctl status mongodb
-
and finally enable it permanently by
$ sudo systemctl enable mongodb
-
to start the daemon
$ sudo mongod
-
to access the shell
$ sudo mongo
mantap cuyyy, your tutorial can solved my problem.