完善生产Redis双中心架构文档

This commit is contained in:
2026-08-24 11:52:49 +08:00
parent cfb979e447
commit 90e2adb1b4
5 changed files with 39 additions and 4 deletions
+8 -4
View File
@@ -80,13 +80,17 @@ Gateway systemd 服务名为 `jayu-cloud-gateway`,默认远端目录为 `/opt/
## Redis
Redis 使用 Sentinel,生产 master 名称为 `mymaster`。主从角色会随故障转移变化,操作前以 Sentinel 查询结果为准。
Redis 使用 Sentinel,生产 master 名称为 `mymaster`。当前为 1 Master + 3 Slave + 5 Sentinel 的双中心高可用架构;主从角色会随故障转移变化,操作前以 Sentinel 查询结果为准。
| 节点 | IP | 中心 | 端口 | 角色 | 校验命令 | 凭据条目 |
| --- | --- | --- | --- | --- | --- | --- |
| redis01 | `192.168.5.104` | 中心1 | `6379,26379` | Redis 数据节点 + Sentinel | `SENTINEL get-master-addr-by-name mymaster` | `redis:redis01` |
| redis02 | `192.168.5.105` | 中心1 | `6379,26379` | Redis 数据节点 + Sentinel | `SENTINEL get-master-addr-by-name mymaster` | `redis:redis02` |
| redis03 | `192.168.10.176` | 中心2 | `6379,26379` | Redis 数据节点 + Sentinel / 中心2降级节点 | `SENTINEL get-master-addr-by-name mymaster` | `redis:redis03` |
| prod-redis01 | `192.168.10.17` | 中心1 | `6379,26379` | Redis 数据节点 + Sentinel;当前 Master | `SENTINEL get-master-addr-by-name mymaster`、`INFO replication` | `redis:prod-redis01` |
| prod-redis02 | `192.168.10.18` | 中心1 | `6379,26379` | Redis 数据节点 + Sentinel;当前 Slave | `SENTINEL get-master-addr-by-name mymaster`、`INFO replication` | `redis:prod-redis02` |
| prod-redis03 | `192.168.10.19` | 中心1 | `6379,26379` | Redis 数据节点 + Sentinel;当前 Slave | `SENTINEL get-master-addr-by-name mymaster`、`INFO replication` | `redis:prod-redis03` |
| prod-redis04 | `192.168.20.13` | 中心2 | `6379,26379` | Redis 数据节点 + Sentinel;当前异地 Slave,`replica-priority=200` | `SENTINEL get-master-addr-by-name mymaster`、`INFO replication` | `redis:prod-redis04` |
| aliyun-newapi-sentinel | `10.66.0.4` | 阿里云 | `26379` | Sentinel 仲裁节点,不承载 Redis 数据 | `SENTINEL ckquorum mymaster` | `ssh:api.yunail.art` |
当前验证基线:`prod-redis01` 为 Master,`connected_slaves=3`;5 个 Sentinel 均返回 `OK 5 usable Sentinels. Quorum and failover authorization can be reached`。Redis 认证和应用侧连接配置只记录在 Nacos 或本机私有敏感连接总表,不写入仓库文档。
## RabbitMQ