远程连接mongodb端口不通怎么解决?
yang
2020-05-14 16:00:243908浏览 · 0收藏 · 0评论
远程连接mongodb端口不通问题:
远程连接mongodb时,配置了防火墙规则,但是27017端口就是连接不上。
查看了mongodb的配置文件(centos中默认安装,配置文件是/ect/mongod.conf)。其中net节点下bindIp,有如下这注释:
lesten to local interface only,comment to listen on all interface。
解决方法:
将bindIP配置项,注释掉。重启mongodb服务即可:
关注公众号,随时随地在线学习