Installing MongoDB Community Edition manually (the hard way)

This installation works for Mac and Linux:

  1. Download the binary files for the version you want of MongoDB from https://www.mongodb.com/download-center#community.
  1. Extract the files from the downloaded file; you can use the terminal and use this command:
    tar -zxvf mongodb-osx-ssl-x86_64-3.6.3.tgz
  1. Copy the extracted folder to the location from which MongoDB will run:
    mkdir -p mongodb    cp -R -n mongodb-osx-ssl-x86_64-3.6.3/ mongodb
  1. Ensure the location of the binaries is in the PATH variable. You can add the following line in your shell's rc file, such as ~/.bashrc or ~/.bash_profile:
    export PATH=<your-mongodb-install-directory>/bin:$PATH 

Get React Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.