mongodb - How to run a mongod instance -


i starter of mongodb. according "import example" section of mongodb 3.2 manual, prerequisite importing data database have running mongod instance. limited background knowledge of mongodb, failed understand line of instruction. please give me explanation on how run mongod instance step step in mac terminal? thanks.

here several steps start mongodb var mongod

  • created ./bin/data/db directory storing mongodb data file.
  • start 1 terminal mongodb server
  • go mongo/bin, , execute command

    ./mongod 
  • start terminal mongodb shell

  • go mongo/bin, , run

    ./mongo 
  • now can connect mongodb now, more command show dbs, show collections, use dbname, more commands in mongodb, refer db.help()...


Comments

Popular posts from this blog

android - Why am I getting the message 'Youractivity.java is not an activity subclass or alias' -

Making Empty C++ Project: General exception (Exception from HRESULT:0x80131500) Visual Studio Community 2015 -

How to fix java warning for "The value of the local variable is not used " -