@herminia_bruen
To restart MongoDB on a Linux machine, follow these steps:
1
|
sudo service mongod stop
|
1
|
sudo service mongod start
|
1
|
sudo service mongod status |
This will show you whether MongoDB is currently running or not.
Alternatively, you can use the following command to restart MongoDB:
1
|
sudo service mongod restart |
This will stop and start MongoDB in one command.