Complete the command to start the MongoDB server.
mongod --[1] /data/dbThe --dbpath option specifies the directory where MongoDB stores its data files.
Complete the command to connect to the MongoDB server using the shell.
mongo --[1] 27017
The --port option specifies the port number to connect to the MongoDB server.
Fix the error in the command to start MongoDB with a custom log file.
mongod --dbpath /data/db --[1] /var/log/mongodb.log --forkThe correct option to specify the log file path is --logpath.
Fill both blanks to create a directory and set permissions for MongoDB data storage.
sudo mkdir -p [1] && sudo chown [2] [1]
The data directory is usually /data/db, and the owner should be the mongodb user for proper permissions.
Fill all three blanks to write a command that installs MongoDB on Ubuntu using apt.
sudo apt-get update && sudo apt-get install -y [1]-org && sudo systemctl [2] [3]
You install the mongodb-org package, then start the mongod service with systemctl start.