Starting mongodb cluster - mongodb

I'm starting 3 mongod processes on 3 different machines and try to run the mongos process on the another machine that runs also the application server.
I'm getting this message:
~$ mongos --configdb mongo1:27017,mongo2:27017,mongo3:27017
Mon Sep 24 10:34:05 mongos db version v2.0.4, pdfile version 4.5 starting (--help for usage)
Mon Sep 24 10:34:05 git version: nogitversion
Mon Sep 24 10:34:05 build info: Linux yellow 2.6.24-29-server #1 SMP Tue Oct 11 15:57:27 UTC 2011 x86_64 BOOST_LIB_VERSION=1_46_1
Mon Sep 24 10:34:09 ERROR: config servers mongo1:27017 and mongo2:27017 differconfig servers mongo1:27017 and mongo2:27017 differconfig servers mongo1:27017 and mongo2:27017 differconfig servers mongo1:27017 and mongo2:27017 differconfig servers not in sync! config servers mongo1:27017 and mongo2:27017 differ
chunks: "d41d8cd98f00b204e9800998ecf8427e" EOO
EOO EOO
configServer startup check failed

I've deleted mongod.lock from all config servers and restarted mongod.
That solved the problem.

There are 2 ways it can be done,
1) clear the data folder and restart the server, it will start as usual without any error,
2) delete the mongod lock file and Use the --repair option.

Related

The command '/bin/sh -c service mongod start' return a non-zero code: 1 in docker

i'm trying to create a docker image run Mongodb on my Raspberry Pi 3+ with Raspbian buster. But when i build image and run container, mongodb doesn't auto start, so i add command RUN service mongod start then build image. Mongodb seems to be installed, i checked by service --status-all and mongodb listed but not started. Error come when docker try to start mongodb serive: The command '/bin/sh -c service mongod start' return a non-zero code: 1.
This is myDockerfile:
FROM cretzel/rpi-mongodb
WORKDIR /usr/src/mongodb
RUN chmod +x /var/lib/mongodb
RUN service mongod start
EXPOSE 27017
CMD ["mongod"]
I tried to fix this and be told that it doesn't have permission, so i add RUN chmod +x /var/lib/mongodb to my dockerfile but it don't work.
Can someone help?
---------------- Update from #Adiii's answer -----------------------------------
My new dockerfile:
FROM cretzel/rpi-mongodb
WORKDIR /usr/src/mongodb
COPY ./entrypoint.sh .
RUN chmod +x ./entrypoint.sh
VOLUME ./database /data/db
EXPOSE 27017
CMD ["mongod"]
entrypoint.sh
#!/bin/bash
service mongod start
exec "$#"
The change solved my error but mongodb service still cannot start. This is log file:
Starting database: mongodb failed!
db level locking enabled: 1
mongod --help for help and startup options
Mon Nov 11 16:31:15
Mon Nov 11 16:31:15 warning: 32-bit servers don't have journaling enabled by default. Please use --journal if you want durability.
Mon Nov 11 16:31:15
warning: some regex utf8 things will not work. pcre build doesn't have --enable-unicode-properties
Mon Nov 11 16:31:15 [initandlisten] MongoDB starting : pid=1 port=27017 dbpath=/data/db/ 32-bit host=38271f34412b
Mon Nov 11 16:31:15 [initandlisten]
Mon Nov 11 16:31:15 [initandlisten] ** NOTE: This is a development version (2.1.1-pre-) of MongoDB.
Mon Nov 11 16:31:15 [initandlisten] ** Not recommended for production.
Mon Nov 11 16:31:15 [initandlisten]
Mon Nov 11 16:31:15 [initandlisten] ** NOTE: when using MongoDB 32 bit, you are limited to about 2 gigabytes of data
Mon Nov 11 16:31:15 [initandlisten] ** see http://blog.mongodb.org/post/137788967/32-bit-limitations
Mon Nov 11 16:31:15 [initandlisten] ** with --journal, the limit is lower
Mon Nov 11 16:31:15 [initandlisten]
Mon Nov 11 16:31:15 [initandlisten] db version v2.1.1-pre-, pdfile version 4.5
Mon Nov 11 16:31:15 [initandlisten] git version: 47fbbdceb21fc2b791d22db7f01792500647daa9
Mon Nov 11 16:31:15 [initandlisten] build info: Linux raspberrypi 3.2.27+ #102 PREEMPT Sat Sep 1 01:00:50 BST 2012 armv6l BOOST_LIB_VERSION=1_49
Mon Nov 11 16:31:15 [initandlisten] options: {}
Mon Nov 11 16:31:15 [initandlisten] waiting for connections on port 27017
Mon Nov 11 16:31:15 [websvr] admin web console waiting for connections on port 28017
Mon Nov 11 16:32:15 [clientcursormon] mem (MB) res:20 virt:83 mapped:0
I don't understand Docker so much, it don't show any error. Please help!
You should not start the process at RUN command, each run command run at a separate shell and RUN is for installation and configuration not to start the process. To start the process in the container you need to start the process at entrypoint or CMD.
also, the container needs a process to run in foreground so service will not work in case of the container. so
EXPOSE 27017
CMD ["mongod"]
This is enough to start the mongo process, if the container is up and running it's mean mongod process is running, you do not need to check the status using service --status-all. as soon as MongoDB process dies container will die automatically.
Will suggest to use offical mongo docker image.

Mongo shell closes immediately

When I launch the mongo shell it closes immediately. There is no error. It was working fine (yesterday). My MongoDB server is running perfectly, and my application is connecting to it fine. I can't even launch the shell without connecting to a database:
C:\mongodb\bin> mongo --verbose
MongoDB shell version: 2.4.7
Fri Mar 27 10:35:38.425 versionArrayTest passed
connecting to: test
Fri Mar 27 10:35:38.472 creating new connection to:127.0.0.1:27017
Fri Mar 27 10:35:38.472 BackgroundJob starting: ConnectBG
Fri Mar 27 10:35:38.487 connected connection!
bye
Fri Mar 27 10:35:38.487 freeing 1 uncollected class mongo::DBClientCursor objects
Fri Mar 27 10:35:38.487 freeing 1 uncollected class mongo::DBClientWithCommands objects
Fri Mar 27 10:35:38.487 freeing 1 uncollected class mongo::BSONHolder objects
Similarly when connecting with no db:
C:\mongodb\bin> mongo --nodb --norc --verbose
MongoDB shell version: 2.4.7
Fri Mar 27 10:37:00.513 versionArrayTest passed
bye
Any and all thoughts on how to connect gratefully received.
As, mongod service has stopped; you need to go in the task manager-> Services Tab
-> search for MongoDB
-> Right click and click start.
You will find mongod shell is working as it was working previously.
I hope this helped!

mongodb cluster upgrade config servers fails

I'm trying to create a mongodb cluster with 3 machines by following this link : http://docs.mongodb.org/manual/tutorial/deploy-shard-cluster/ . I have downloaded mongodb 2.6.4 to all machines and started config servers with this command :
mongod --configsvr --dbpath /home/sshusr/mongodb/data/configdb/
and I'm trying to start a mongos instance to upgrade config servers to v5 because it tells me to do that. So I run this command
mongos --upgrade --configdb 10.122.123.64:27019,10.122.123.65:27019,10.122.123.66:27019
but it gives me this
2014-09-26T17:07:55.629+0300 [mongosMain] MongoS version 2.6.4 starting: pid=50066 port=27017 64-bit host=tesla (--help for usage)
2014-09-26T17:07:55.629+0300 [mongosMain] db version v2.6.4
2014-09-26T17:07:55.629+0300 [mongosMain] git version: 3a830be0eb92d772aa855ebb711ac91d658ee910
2014-09-26T17:07:55.629+0300 [mongosMain] build info: Linux build7.nj1.10gen.cc 2.6.32-431.3.1.el6.x86_64 #1 SMP Fri Jan 3 21:39:27 UTC 2014 x86_64 BOOST_LIB_VERSION=1_49
2014-09-26T17:07:55.629+0300 [mongosMain] allocator: tcmalloc
2014-09-26T17:07:55.629+0300 [mongosMain] options: { sharding: { configDB: "10.122.123.64:27019,10.122.123.65:27019,10.122.123.66:27019" }, upgrade: true }
2014-09-26T17:07:55.633+0300 [mongosMain] SyncClusterConnection connecting to [10.122.123.64:27019]
2014-09-26T17:07:55.633+0300 [mongosMain] SyncClusterConnection connecting to [10.122.123.65:27019]
2014-09-26T17:07:55.633+0300 [mongosMain] SyncClusterConnection connecting to [10.122.123.66:27019]
2014-09-26T17:07:55.718+0300 [mongosMain] scoped connection to 10.122.123.64:27019,10.122.123.65:27019,10.122.123.66:27019 not being returned to the pool
2014-09-26T17:08:06.770+0300 [mongosMain] waited 11s for distributed lock configUpgrade for upgrading config database to new format v5
2014-09-26T17:08:17.816+0300 [mongosMain] waited 22s for distributed lock configUpgrade for upgrading config database to new format v5
2014-09-26T17:08:28.863+0300 [mongosMain] waited 33s for distributed lock configUpgrade for upgrading config database to new format v5
2014-09-26T17:08:39.909+0300 [mongosMain] waited 44s for distributed lock configUpgrade for upgrading config database to new format v5
....
what am I missing here? Any help is appreciated. Thanks.
I have resolved the problem.
I executed the command with verbose and saw that there was a time/date difference between servers. I have assigned an ntp server for each server and problem was solved.

how to set mongod --dbpath

very new to mongodb and databases in general. whenever i run mongo i receive this error message: ​​​
MongoDB shell version: 2.4.9
connecting to: test
Thu Jan 30 13:03:33.170 Error: couldn't connect to server 127.0.0.1:27017
at src/mongo/shell/mongo.js:145
exception: connect failed
running mongod i see this:
Thu Jan 30 13:13:36.588 [initandlisten] MongoDB starting : pid=29408 port=27017 dbpath=/usr/local/var/mongodb 64-bit host=Kimis-MacBook-Air-2.local
Thu Jan 30 13:13:36.588 [initandlisten]
Thu Jan 30 13:13:36.588 [initandlisten] ** WARNING: soft rlimits too low. Number of files is 256, should be at least 1000
Thu Jan 30 13:13:36.588 [initandlisten] db version v2.4.9
Thu Jan 30 13:13:36.588 [initandlisten] git version: nogitversion
Thu Jan 30 13:13:36.588 [initandlisten] build info: Darwin minilionvm.local 11.4.2 Darwin Kernel Version 11.4.2: Thu Aug 23 16:25:48 PDT 2012; root:xnu-1699.32.7~1/RELEASE_X86_64 x86_64 BOOST_LIB_VERSION=1_49
Thu Jan 30 13:13:36.588 [initandlisten] allocator: tcmalloc
Thu Jan 30 13:13:36.588 [initandlisten] options: { bind_ip: "127.0.0.1", config: "/usr/local/etc/mongod.conf", dbpath: "/usr/local/var/mongodb" }
Thu Jan 30 13:13:36.591 [initandlisten] journal dir=/usr/local/var/mongodb/journal
Thu Jan 30 13:13:36.591 [initandlisten] recover begin
Thu Jan 30 13:13:36.591 [initandlisten] recover lsn: 108155770
Thu Jan 30 13:13:36.591 [initandlisten] recover /usr/local/var/mongodb/journal/j._0
Thu Jan 30 13:13:36.591 [initandlisten] journal file version number mismatch got:4147 expected:4149. if you have just upgraded, recover with old version of mongod, terminate cleanly, then upgrade.
Thu Jan 30 13:13:36.592 [initandlisten] dbexception during recovery: 13536 journal version number mismatch 16711
Thu Jan 30 13:13:36.592 [initandlisten] exception in initAndListen: 13536 journal version number mismatch 16711, terminating
Thu Jan 30 13:13:36.592 dbexit:
Thu Jan 30 13:13:36.592 [initandlisten] shutdown: going to close listening sockets...
Thu Jan 30 13:13:36.592 [initandlisten] shutdown: going to flush diaglog...
Thu Jan 30 13:13:36.592 [initandlisten] shutdown: going to close sockets...
Thu Jan 30 13:13:36.592 [initandlisten] shutdown: waiting for fs preallocator...
Thu Jan 30 13:13:36.592 [initandlisten] shutdown: lock for final commit...
Thu Jan 30 13:13:36.592 [initandlisten] shutdown: final commit...
Thu Jan 30 13:13:36.592 [initandlisten] shutdown: closing all files...
Thu Jan 30 13:13:36.592 [initandlisten] closeAllFiles() finished
Thu Jan 30 13:13:36.592 [initandlisten] shutdown: removing fs lock...
Thu Jan 30 13:13:36.592 dbexit: really exiting now
when i manually set my mongo dpath to mongod --dbpath /data/db (as should be the default on installation) and keep it running in terminal everything runs fine. but once i close it, everything breaks again. my question is:
why is my dbpath set to /usr/local/var/mongodb?
how do i fix this error so mongo works on my machine?
i'm assuming i either need to permanently set the dbpath to /data/db or reconfigure something so it works with the dbpath as /usr/local/var/mongodb
i fairly new to unix commands as well so not entirely sure how to fix this error.
thank you for any suggestions!
so, digging through the mongodb documentation i read this:
"Unless specified, mongod will look for data files in the default /data/db directory. (Windows systems use the \data\db directory.) If you installed using a package management system. Check the /etc/mongodb.conf file provided by your packages to see the configuration of the dbpath."
when i took a look at the files within /etc/ there is no mongodb.conf file... however, i do see /usr/local/etc/mongod.conf... so if i understand this correctly, i should create a file called /etc/mongodb.conf and set the dbpath to /data/db.
do i need to delete the stuff within /usr/local/ as well?
i think this has something to do with how my PATH are setup... could someone explain to me how to fix this in unix so i won't have this problem?
thanks again!
Have only tried this on Mac:
Create a data directory in the root folder of your app
cd into your wherever you placed your mongo directory when you installed it
run this command:
mongod --dbpath ~/path/to/your/app/data
You should be good to go!
You can set dbPath in the mongodb.conf file:
storage:
dbPath: "/path/to/your/database/data/db"
It's a YAML-based configuration file format (since Mongodb 2.6 version), so pay attention no tabs only spaces, and space after ": "
usually this file located in the *nix systems here: /etc/mongodb.conf
So then just run
$ mongod -f /etc/mongodb.conf
And mongod process will start...
(on the Windows something like)
> C:\MongoDB\bin\mongod.exe -f C:\MongoDB\mongod.conf
First you will have a config file in /etc/mongodb.conf, therefore this sounds like a homebrew install which will use some more standardized paths. The whole /data/db/ thing is referenced in a lot of manual install documentation.
So basically from your log the server is not running, it's shutting down, so there is nothing for the shell to connect to. Seems like you have had some unclean shutdowns/restarts which has led to the inconsistency.
Clear the files in the journal /usr/local/var/mongodb/journal/ on your config.
Also:
sudo rm /var/lib/mongodb/mongod.lock
Just in case, even though that part looks clean. And then restart.
For me it must have:
mongod --dbpath=/whatever/data/path
Create a directory db in home, inside db another directory data
cd
mkdir db
cd db
mkdir data
then type this command--
mongod --dbpath ~/db/data
mongod --port portnumber --dbpath /path_to_your_folder
By default portnumber is 27017 and path is /var/lib/mongodb
You can set your own port number and path where you want to keep all your database.
You could also configure mongod to run on start up so that it is automatically running on start up and the dbpath is set upon configuration. To do this try:
mongod --smallfiles --config /etc/mongod.conf
The --smallfiles tag is there in case you get an error with size. It is, of course, optional. Doing this should solve your problem while also automating your mongodb setup.
sudo mongod --dbpath ~/data
This made it work for me.
very simple:
sudo chown mongodb:mongodb /var/lib/mongodb/mongod.lock
Scenario: MongoDB(version v4.0.9).
Set custom folder(with name: myCustomDatabases), where to store databases.
In custom folder(with name: myCustomDatabases), have to create database (with name: newDb).
Resolve:
Create custom folder(with name: myCustomDatabases):
D:>md myCustomDatabases
Run 'mongod --dbpath' with path to custom folder(with name: myCustomDatabases):
mongod --dbpath "D:\myCustomDatabases"
From another 'cmd' run 'mongo':
D:>mongo
3.1. Show all databases, stored in custom folder(with name: myCustomDatabases):
>show dbs
admin 0.000GB
config 0.000GB
local 0.000GB
3.2. Use database with name newDb:
> use newDb
switched to db newDb
3.3. Show all databases, stored in custom folder(with name: myCustomDatabases):
>show dbs
admin 0.000GB
config 0.000GB
local 0.000GB
!!! Noticed, that newDb is NOT in the list !!!
3.4. Have to create a collection with a document,
which will create the database newDb.
> db.Cats.insert({name: 'Leo'})
WriteResult({ "nInserted" : 1 })
The insert({name: 'Leo'}) operation creates:
the database newDB and the collection Cats, because they do not exist.
3.5. Now the new created database newDb will be displayed in the list.
> show dbs
admin 0.000GB
config 0.000GB
local 0.000GB
newDb 0.000GB
3.6. Now in custom folder D:\myCustomDatabases, have database newDb.
Windows environment, local machine.
I had an error
[js] Error: couldn't connect to server 127.0.0.1:27017, connection attempt failed: SocketException:
Error connecting to 127.0.0.1:27017 :: caused by ::
No connection could be made because the target machine actively refused it. :
After some back and forth attempts I decided
to check Windows "Task Manager". I noticed that MongoDB process is stopped.
I made it run. Everything starts working as expected.
You can use --dbpath flag in order to provide it with the parameters i.e, the directory address. I found it useful for Windows 10 OS.
With the default settings it is usually not required.
Go to the directory you would like your data to be saved in.
Create a folder called "mongodb" and within it create another directory named "data"
Navigate back to the "mongodb" directory in the terminal window and place the following line of mongod --dbpath=data --bind_ip 127.0.0.1
Run this command each time you want to start up the mongodb database
With the terminal command mongod --dbpath /YOUR/PATH/TO/DATA/ I need to type it everytime I want to start MongoDB. Somehow setting it in the mongo.conf didn't load the path properly. I found a solution to avoid having to type the long command every time by adding an alias in ~/.zshrc
Shut down MongoDB (while mongo is running type in Terminal: use admin press enter and on a next line db.shutdownServer().
Close the Terminal window.
Open ~/.zshrc or when your macOS is using bash-shell open ~/.bash_profile
Add in the file: alias -g mongod="MongoDB --dbpath /YOUR/PATH/TO/DATA/
Save your .zshrc or .bash_profile file
Open Terminal
Type source ~/.zshrc or for bash-shell users: source ~/.bash_profile
Type mongod
MongoDB should now be running with the right path and connection. Terminal can be closed now. To check whether mongo is running open Terminal, type mongo which gives you the interface in Terminal or type top and check mongo in the list of applications.

MongoDB provides a basic authentication system. Has it changed in version 2.2.3?

Scenario: Installed MongoDB 2.2.3 on the machine (Windows 64-bit)
Followed all the steps to enforce authentication on MongoDB server.
Added User to admin database
use admin
db.addUser('me_admin', '12345');
db.auth('me_admin','12345');
Ran database server (mongod.exe process) with the --auth option to enable
authentication
Followed all answers for similar question:
How to secure MongoDB with username and password
Issue: With new version 2.2.3 I am not able set up authentication. After following the same steps I was able to set up the authentication for the version 2.0.8 on the same machine. But its mentioned somewhere in MongoDB docs that "Authentication on Localhost varies slightly between before and after version 2.2"
Question: What is the change and how can enforce the authentication in new versions i.e. 2.2 onwards. Can anybody give some idea or solution to proceed the same with new MongoDB 2.2.3?
Update:
I had checked that authentication works same on 2.2.3 when I start mongod.exe process with --auth parameter from command prompt.
I was using auth=true parameter in config file as mentioned in docs, but this did not work.
Research done:
When mongod.cfg file contains following configurations
logpath=c:\mongodb\log\mongo.log, auth=true, profile=2
The log.txt file contains following logs
Mon Mar 11 15:06:35 Trying to start Windows service 'MongoDB'
Mon Mar 11 15:06:35 Service running
Mon Mar 11 15:06:35 [initandlisten] MongoDB starting : pid=7152 port=27017 dbpath=\data\db\ 64-bit host=AMOL-KULKARNI
Mon Mar 11 15:06:35 [initandlisten] db version v2.2.3, pdfile version 4.5
Mon Mar 11 15:06:35 [initandlisten] git version: f570771a5d8a3846eb7586eaffcf4c2f4a96bf08
Mon Mar 11 15:06:35 [initandlisten] build info: windows sys.getwindowsversion(major=6, minor=1, build=7601, platform=2, service_pack='Service Pack 1') BOOST_LIB_VERSION=1_49
Mon Mar 11 15:06:35 [initandlisten] options: { config: "C:\mongodb\mongod.cfg", logpath: "c:\mongodb\log\mongo.log auth=true profile=2", service: true }
Mon Mar 11 15:06:35 [initandlisten] journal dir=/data/db/journal
Mon Mar 11 15:06:35 [initandlisten] recover : no journal files present, no recovery needed
Mon Mar 11 15:06:35 [initandlisten] waiting for connections on port 27017
Mon Mar 11 15:06:35 [websvr] admin web console waiting for connections on port 28017
When I run from command prompt mongod --auth, following log will be displayed:
Mon Mar 11 15:09:40 [initandlisten] MongoDB starting : pid=6536 port=27017 dbpath=\data\db\ 64-bit host=AMOL-KULKARNI
Mon Mar 11 15:09:40 [initandlisten] db version v2.2.3, pdfile version 4.5
Mon Mar 11 15:09:40 [initandlisten] git version: f570771a5d8a3846eb7586eaffcf4c2f4a96bf08
Mon Mar 11 15:09:40 [initandlisten] build info: windows sys.getwindowsversion(major=6, minor=1, build=7601, platform=2, service_pack='Service Pack 1') BOOST_LIB_VERSION=1_49
Mon Mar 11 15:09:40 [initandlisten] options: { auth: true }
Mon Mar 11 15:09:40 [initandlisten] journal dir=/data/db/journal
Mon Mar 11 15:09:40 [initandlisten] recover : no journal files present, no recovery needed
Mon Mar 11 15:09:40 [initandlisten] waiting for connections on port 27017
Mon Mar 11 15:09:40 [websvr] admin web console waiting for connections on port 28017
Note: The change in the options:
options:{ config: "C:\mongodb\mongod.cfg", logpath:
"c:\mongodb\log\mongo.log auth=true profile=2", service: true } //Does not work
options: { auth: true } //Works
Interesting to observe is that,
When its ran from config file.
logpath=c:\mongodb\log\mongo.log, auth=true, profile=2
It got changed to:
logpath: "c:\mongodb\log\mongo.log auth=true profile=2", service: true
I know here is the issue. It should be like:
logpath: "c:\mongodb\log\mongo.log", auth=true, profile="2", service: true
So, the question is how to pass auth=true parameter from config file and run mongod.exe process as service on Windows7
The change is only minor as described under the part you quoted:
In general if there are no users for the admin database, you may connect via the localhost interface. For sharded clusters running version 2.2, if mongod is running with auth then all users connecting over the localhost interface must authenticate, even if there aren’t any users in the admin database.
Basically before 2.2 if you were in a sharded cluster you could connect to localhost and not be forced to auth if there are no users found in the admin database. This means that if you set-up a sharded cluster it might be wise to setup a default user, which you have already done.
Can anybody give some idea or solution to proceed the same with new MongoDB 2.2.3?
The new auth system will just be there, you don't need to do anything; it just will be.
Found out the solution.
To run MongoDB process (mongod.exe) as service with auth=true, following has to be taken care while registering MongoDB service itself (not mentioned in docs)
Service has to be registered with following command:
C:\mongodb\bin\mongod.exe --config C:\mongodb\mongod.cfg --auth --install
mongod.cfg file will have only logpath=c:\mongodb\log\mongo.log
Shared with you all so that effort & time will not be put on the same issue again.
Happy exploring to all.. :-)
Note this time log contains:
Mon Mar 11 15:58:06 Trying to start Windows service 'MongoDB'
Mon Mar 11 15:58:06 Service running
Mon Mar 11 15:58:06 [initandlisten] MongoDB starting : pid=6800 port=27017 dbpath=\data\db\ 64-bit host=AMOL-KULKARNI
Mon Mar 11 15:58:06 [initandlisten] db version v2.2.3, pdfile version 4.5
Mon Mar 11 15:58:06 [initandlisten] git version: f570771a5d8a3846eb7586eaffcf4c2f4a96bf08
Mon Mar 11 15:58:06 [initandlisten] build info: windows sys.getwindowsversion(major=6, minor=1, build=7601, platform=2, service_pack='Service Pack 1') BOOST_LIB_VERSION=1_49
Mon Mar 11 15:58:06 [initandlisten] options: { auth: true, config: "C:\mongodb\mongod.cfg", logpath: "c:\mongodb\log\mongo.log", service: true }
Mon Mar 11 15:58:06 [initandlisten] journal dir=/data/db/journal
Mon Mar 11 15:58:06 [initandlisten] recover : no journal files present, no recovery needed
Mon Mar 11 15:58:06 [initandlisten] waiting for connections on port 27017
Mon Mar 11 15:58:06 [websvr] admin web console waiting for connections on port 28017