Steps
On the machine on which you installed MongoDB Community Edition, select the Windows Start button, then navigate to and right-click Command Prompt, and then select Run as administrator.
A command prompt window appears.
On the command prompt window, enter the following:
mkdir c:\data\db
mkdir c:\data\log
Two directories that will be used by APM System Monitoring are created.
Create a configuration (.cfg) file. The file must set systemLog.path. Include additional configuration options as needed. For example, to create a file at C:\data\mongod.cfg that specifies both systemLog.path and storage.dbPath, the file would contain the following text:
systemLog:
destination: file
path: c:\data\log\mongod.log
storage:
dbPath: c:\data\db
Note: In the configuration file, each tab indentation seen in the preceding text should be replaced with two spaces.
On the command prompt window, enter the following:
Note: To use an alternate dbpath, specify the path in the configuration file (e.g., C:\data\mongod.cfg) or on the command line with the --dbpath option.
The MongoDB service is installed.
On the command prompt window, enter the following:
The MongoDB service is started, and the Windows service is configured.
What's Next?
Copyright © 2018 General Electric Company. All rights reserved.