Configure MongoDB Auto-start and remote connection on the database Mean Web development 05-linux

Source: Internet
Author: User
Tags mongodb client mongodb query

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

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.