MongoDB Quick Guide to Installation, Start, Stop and Restart

posted in: MongoDB | 0

Introduction

The following tutorial shows how to install, start, stop, and restart MongoDB.

Download/Installation

Ubuntu

The commands below do the following:

  1. Imports public key used by package management system.
  2. Create a list file for MongoDB.
  3. Reload local package database.
  4. Install the MongoDB packages.
sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv 7F0CEB10
echo 'deb http://downloads-distro.mongodb.org/repo/ubuntu-upstart dist 10gen' | sudo tee /etc/apt/sources.list.d/mongodb.list
sudo apt-get update
sudo apt-get install mongodb-org

Start/Status/Stop/Restart

Start

sudo service mongod start

Check if running

nano /var/log/mongodb/mongod.log

Stop

sudo service mongod stop

Restart

sudo service mongod restart

перманентный макияж

Leave a Reply