Reputation: 6686
Can i run more that one instance of MongoDB on one Windows-machine?
Upvotes: 0
Views: 1177
Reputation: 389
Yes, you can run more than one service on Windows.
On mongodb 1.8 you have a new option --serviceDisplayName that allow you to run multiple services, of course you have to use different port.
For example :
"C:\Mongodb\bin\mongod" --bind_ip your-ip-adress --logpath "C:\data\db\mongo.log" --logappend --dbpath "C:\data\db" --serviceName MongoServiceTest --serviceDisplayName MongoServiceTest --port 27017 --install
Upvotes: 0
Reputation: 27080
Yes, I'm running 4 (on different ports) ...
You might be asking can you run more than one SERVICE?
The answer is no (at the moment) at least not the way you are supposed to ...
http://www.mongodb.org/display/DOCS/Windows+Service
This is supposed to be fixed in the next verision (1.7)
http://jira.mongodb.org/browse/SERVER-1590
However, there are some work-arounds you can use, see here ...
Mongodb, sharding and multiple windows services
Upvotes: 2