search

Home  >  Q&A  >  body text

Link MongoDB Error: mongodb network is unreachable How to solve?

The link worked well yesterday, but today the link reported an error. I tried various methods on Baidu but it didn’t work. The MongoDB service did not try to restart because it has been in use.
Please help me solve it. Or give me some ideas, thank you

MongoDB restricts IP, so there is no AUTH.

習慣沉默習慣沉默2788 days ago1073

reply all(1)I'll reply

  • 伊谢尔伦

    伊谢尔伦2017-05-02 09:27:55

    First of all, for security reasons, it is recommended to turn on auth regardless of whether the IP is restricted or not. It is recommended to turn it on when appropriate.
    "It worked fine yesterday" and "The link reported an error today" are actually not necessarily related, right? Even if it was fine yesterday, it doesn't prove that there won't be any problems today or in the future. So just focus on the current issues. Sorry for being a bit verbose, I am a bit obsessive about logical rigor:)
    First check whether the process exists and whether the monitoring is normal:

    ps aux | grep mongod
    netstat -pln | grep mongod

    Usually the situation should be that mongod has been terminated. Please check your log for the specific reason. By default located at:

    /var/log/mongod.log

    If there are any modifications, please check them yourself. It is recommended to check the last situation of the log. You should see dbexit. Show the last 50 lines and let us continue the analysis.

    reply
    0
  • Cancelreply