MongoDb is no-sql database. Their site is http://www.mongodb.org where you can find more information. First we need to download the mongodb from http://www.mongodb.org/downloads. I am using the version for Windows 64.
We can now unzip the content in the folder we want, for example in C:. Inside that folder, we need to create a folder named "Data" and a folder named "Logs" (Data folder is required, but Logs folder not, however, we will use it in this post).
We create a file named log.txt inside the Logs folder.
Now, let's start the database. We open a command-line (with administrative rights) and we go where we have placed our MongoDb folder. Inside the 'bin' folder, we have the executables. Let's now install the mongodb as a windows service.
To do that, we need to execute the next command:
mongod --bind_ip 127.0.0.1 --logpath c:\mongo\logs\log.txt
--logappend --dbpath c:\mongo\data --directoryperdb --install
This will install mongodb as a windows service. It is important to create the log.txt file before, in order to avoid errors. Finally we can check that everything went ok by accesing the url:
It must show the MongoDb server page. That's all ;).
No hay comentarios:
Publicar un comentario