Mac MongoDB Connect failed connection Error resolution

Source: Internet
Author: User
Tags mongodb mongodb server

These days have been tossing the MongoDB database, has been the following this problem

MongoDB Shell version v3.6.0connecting TO:MONGODB://127.0.0.1:27017in for  Error after poll), Reason:connection refused2017-12-27t09:54:34.778+0800 E QUERY [thread1] error:couldn ' t connect to server 127.0.0.1:27017, connection attempt failed: [Email protected]/mongo/shell/mongo.js:237:13@ ( Connect): 1:6exception:connect failed

Try all sorts of ways.

This error occurs when the MongoDB service is not running

The attempt to create a new/data/db directory does not work.

Later through search, find the arrival solution, run the command

Brew Services Start MongoDB

To call the database command again

Mongo

We can solve the problem perfectly.

Tips for successful display under the final Mac

MongoDB Shell version v3.6.0connecting TO:MONGODB://127.0.0.1:27017MongoDB Server version : 3.6.02017-12-27t09:54:58.316+0800 i control  2017-12-27t09:54:58.316+0800 I control   for the database. 2017-12-27t09:54:58.316+0800 i CONTROL  [initandlisten] * *          Read and write access to data and configuration I s unrestricted. 2017-12-27t09:54:58.316+0800 I CONTROL  

Mac MongoDB Connect failed connection Error resolution

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.