Commit bbc41b3c11724d94fe68201f76871320c0f5c161
1 parent
5578d333
Mongo DB config file
Showing
1 changed file
with
38 additions
and
0 deletions
150-DOCUMENTATION/001-CONFIGURATION/MongoConfig
0 → 100644
1 | +1. downlaod and install mongoDB from "https://www.mongodb.com/download-center#community". | |
2 | +2. create a folder mongoadmin somewhere in your D:\ | |
3 | +3. create 3 folders within this folder with the following names: | |
4 | + conf | |
5 | + data | |
6 | + log | |
7 | + 4. Place mongod.conf file in conf folder. Contents of file are below. | |
8 | + | |
9 | + storage: | |
10 | + dbPath: "d:/mongoadmin/data" | |
11 | + journal: | |
12 | + enabled: true | |
13 | + | |
14 | + systemLog: | |
15 | + destination: file | |
16 | + path: "d:/mongoadmin/log/mongod.log" | |
17 | + | |
18 | + net: | |
19 | + http: | |
20 | + enabled: true | |
21 | +5. run command to install mongodb as windows service and in that command give the mongod.conf file's path as a parameter. | |
22 | + 'mongod.exe --config "d:\mongoadmin\conf\mongod.conf" --install' | |
23 | +mong if you do not install mongodb as a service, then you need to run mongod.exe everytime you want to have mongodb running | |
24 | +6. after executing the above command, you can run the following command to start MongoDB service | |
25 | + "net start MongoDB" | |
26 | + to execute all the above commands, you need to open command with "run as administrator" | |
27 | + | |
28 | +------------- | |
29 | +@TO DUMP DATABASE | |
30 | +mongodump -d <dataabseNme> -o <target diectory> | |
31 | + | |
32 | +@TO RESTORE DB | |
33 | +mongorestore --db <database_name> <path_to_bson_file> | |
34 | + | |
35 | + | |
36 | +-------- | |
37 | +@Install MongoBooster | |
38 | +and add DB name in create connection Default Database tab. | |
0 | 39 | \ No newline at end of file | ... | ... |