Brief introduction
Mean is a full stack development framework for JavaScript. More about
The storage of persistent data with MongoDB is a part of mean web full stack development.
MongoDB is a product between a relational database and a non-relational database, and is the most versatile and most like relational database in a non-relational database. It is characterized by high performance, easy to deploy, easy to use, and easy to store data.
MongoDB's learning materials can be consulted:
MongoDB Chinese Community
The previous section describes the installation and problems of MongoDB on Linux, which describes the automatic start-up and remote connection of MongoDB on Linux.
Start automatically on Linux
Edit the following file:
Vi/etc/rc.d/rc.local
Use the VI Editor to open the configuration file and add the following line of code to it
/usr/local/mongodb/bin/mongod-dbpath=/usr/local/mongodb/data/db--port 27017
Then reboot the server and enter it into the User/local/mongodb/bin directory./mongo See if there is an auto-start:
The above information appears to start automatically, and then enter the MONGODB query statement below to view the database:
Remote connection
Connect remotely using the NoSQL Manager for MongoDB Client Management tool.
1. Open the client, create a new connection, enter the host's IP and account information
2. Click SSH options to configure the connection:
3. After the connection is successful, double-click to view the database information:
The next article introduces MongoDB combined with client management software for the basic operation of data processing
Configure MongoDB Auto-start and remote connection on the database Mean Web development 05-linux