I am trying to install MongoDB on Windows Azure VM which is running Windows 2012 Server
- I have mongodb in C:\Program Files\MongoDB\bin
- I have config file at D:\mongodb\mongod.cfg
And my config looks like this
logpath=d:\mongodb\log\mongod.log
dbpath=d:\mongodb\data\db
port=27018
now I want to run mongo db from config file so i go to command prompt and run below command
c:\Program Files\MongoDB\bin>mongod --config "D:\mongodb\mongod.cfg"
this stays silent on command prompt no further response.
Then I tried c:\Program Files\MongoDB\bin>mongod --config "D:\mongodb\mongod.cfg" --install
that give me bellow message
2014-05-02xxxxxx log file "d:mongodb\log\mongod.log" exists; moved to "d:mongodb\log\mongod.log.2014-05-02xxxxx"
I guess this is just creating a log file for me.
Now if I run mongod.exe
it give me error saying dbpath (\data\db\) does not exist. But in my config file i gave the path as dbpath=d:\mongodb\data\db
Changed my config file to YAML
systemLog:
destination: file
path: "e:\\mongodb\\log\\mongod.log"
quiet: true
logAppend: true
net:
bindIp: 127.0.0.1
port: 27018
storage:
journal:
enabled: true
dbPath: "e:\\mongodb\\data\\db"
now I run mongod --config "C:\MongoDB 2.6 Standard\mongod.cfg" no response.