Unable to connect Aliyun database MongoDB version problem __ Database

Source: Internet
Author: User
Tags mongodb version aliyun
First, the use of Aliyun database MongoDB version, the external network can not access the problem
1. The MongoDB version of the cloud database does not support external network access. You must install RINETD in Aliyun server ECS for forwarding implementations.
2. The Aliyun server must be redis in the same area as the cloud database (for example, all North China 1), if two are not in the same area and cannot be accessed
3. To access the MongoDB database using the Aliyun server, you must change the classic network type in MongoDB to a professional network type (mongdb default classic network type)
3. In the classic network into a proprietary network, if you meet the Vswitch dropdown box does not have a value problem, to see if there are virtual switches, if you have to see if your virtual Exchange and MongoDB is in one area (for example, all of North China 1 a), two not in one area can not be converted
Second, configure extranet access MongoDB database
1. Want to extranet access MongoDB must use Aliyun server (ECS) installation rinetd forwarding implementation (Aliyun document address: https://help.aliyun.com/document_detail/54553.html)
1). wget HTTP://WWW.BOUTELL.COM/RINETD/HTTP/RINETD.TAR.GZ&&TAR-XVF RINETD.TAR.GZ&&CD rinetd
Sed-i ' s/65536/65535/g ' rinetd.c (Modify port range)
Mkdir/usr/man&&make&&make Install
2). Open the configuration file rinetd.conf
Vi/etc/rinetd.conf
3). Enter the following in the configuration file
0.0.0.0 3717 MongoDB's link address 3717
Logfile/var/log/rinetd.log
4). Perform the following command to start
Rinetd
If you encounter a binding error, you can perform a pkill rinetd end process, and then execute the rinetd start process rinetd.
Rinetd after normal startup, perform NETSTAT-ANP | grep 3717 confirms that the service is operating correctly.
2. Test on the local server
1. Use MONGO--host 1.1.1.1:3717-u root-p Password--authenticationdatabase admin
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.