1> starting the database
1.1> Add the following directories in turn:
1.1.1> Mongodb-space
1.1.2> mongodb-space/conf
1.1.3> Mongodb-space/data
1.1.4> Mongodb-space/log
1.2> Add the global-6969.conf file under the mongodb-space/conf directory.
1.3> writes the following configuration to the global-6969.conf file:
Port = 6969bind_ip = Localhostdbpath =/users/morton/mongodb-space/data/global-6969logpath =/Users/Morton/ Mongodb-space/log/global-6969.loglogappend = Truepidfilepath =/users/morton/mongodb-space/data/global-6969/ Global-6969.pidfork = True
1.3.1> Note: The path configuration in which you use the absolute path is based on your native environment.
1.4> executes the mongod-f/users/morton/mongodb-space/conf/global-6969.conf command, which starts the database.
1.4.1> tip: This step is to create & start the MongoDB database service instead of the database, where you can create multiple databases.
1.4.2> tip: The data file is stored in the directory specified by the global-6969.conf file DBPath entry.
2> Connection Database
2.1> executes the MONGO Localhost:6969/susulink command, that is, the database is connected and the database name is Susulink.
MongoDB-Start & Connect database