MongoDB 副本集+分片 认证方式搭建
参考资料:
https://www.cnblogs.com/ityouknow/p/7344005.html
https://jorwen-fang.iteye.com/blog/2031756
https://www.cnblogs.com/bjx2020/p/9350232.html
https://www.jb51.net/article/161315.htm
https://blog.51cto.com/beigai/1751381
环境规划:
服务器1 192.168.142.138 | 服务器1 192.168.142.139 | 服务器1 192.168.142.140 |
mongos:20000 | mongos:20000 | mongos:20000 |
config:21000 | config:21000 | config:21000 |
shard1:28001(主节点) | shard1:28001(副本节点) | shard1:28001(仲裁节点) |
shard2:28002(仲裁节点) | shard2:28002(主节点) | shard2:28002(副本节点) |
shard3:28003(副本节点) | shard3:28003(仲裁节点) | shard3:28003(主节点) |
1. 关闭SElinux
sed -i ‘s/SELINUX=enforcing/SELINUX=disabled/‘ /etc/selinux/config
grep SELINUX=disabled /etc/selinux/config
setenforce 0
getenforce
原文地址:https://www.cnblogs.com/bjx2020/p/11276091.html
时间: 2024-10-27 19:13:54