1

I'm sorry for this (peraphs) stupid question ... I install meteor and mongodb in my windows computer and i start to write some apps. I don't understand how to use mongo for shoving my db app ... i open one shell in my app dir and launch mongod, in one more shell in the same folder i start mongo.

show dbs
local
use local
switched to db local
show collections
startup_log
system.indexes

Where are my collections? Where is users collection?

Cœur
  • 37,241
  • 25
  • 195
  • 267
IfThenElse
  • 485
  • 5
  • 13

3 Answers3

3

When your app is running use this command on a separate command line mongo 127.0.0.1:3001

Meteor keeps the collections in this server. After you run mongo on this server, by writing use meteor you can use db specific to your running app. And then you can display your collections with db.getCollectionNames()

Cagri Yardimci
  • 3,479
  • 1
  • 11
  • 15
1

To display all your MongoDB collections using the shell, you may check this answer: How to list all collections in the mongo shell?

You may also use a MongoDB GUI Tool such Robomongo

Community
  • 1
  • 1
yaitloutou
  • 1,691
  • 19
  • 23
  • Yes I see this post, I don't understand how to "connect" with the app db, i see only local db and there is no collections – IfThenElse Dec 04 '16 at 19:05
  • for further users, to get the configuration details, and the connection string, you can run: `meteor mongo -U` By the way, meteor stores data in server-side collections, client-side collections and collections accessible by both side, which can be a bit confusing at first. I think this [guide](http://meteortips.com/first-meteor-tutorial/databases-part-1/) may help – yaitloutou Dec 04 '16 at 19:45
1

Meteor uses a library called Minimongo that's why it doesn't display if you run show dbs on your mongo shell.

By default it points to port 3001 hence if you are using Robomongo you can just make the set up to watch that port.

Walter G.
  • 135
  • 4
  • 12