You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

无法将外部节点接入Percona MongoDB主副本集集群的问题求助

无法将外部节点接入Percona MongoDB主副本集集群的问题求助

大家好,我遇到了一个关于Percona MongoDB Operator和外部节点接入的问题,想请各位帮忙排查一下:

我在OpenShift集群上通过Percona Operator部署了MongoDB副本集,现在尝试把一个非托管集群的节点接入到这个主集群中。我已经在副本集的配置里添加了这些外部节点,并且开启了NodePort来暴露服务,具体配置片段如下:

replsets:
- size: 3
  expose:
    enabled: true
    exposeType: NodePort
  resources:
    limits:
      cpu: 300m
      memory: 0.5G
    requests:
      cpu: 300m
      memory: 0.5G
  externalNodes:
    - host: 10.115.199.188
      port: 30320
      priority: 0
      votes: 0
    - host: 10.151.44.88
      port: 32655
      priority: 0
      votes: 0
    - host: 10.198.42.20
      port: 30598
      priority: 0
      votes: 0

但当我连接数据库查看副本集状态时,发现这些外部节点完全无法和主集群通信,每个节点的健康状态都显示异常。以下是其中一个节点的状态信息:

{
  _id: 12,
  name: '10.115.199.188:30320',
  health: 0,
  state: 8,
  stateStr: '(not reachable/healthy)',
  uptime: 0,
  optime: { ts: Timestamp({ t: 0, i: 0 }), t: Long("-1") },
  optimeDurable: { ts: Timestamp({ t: 0, i: 0 }), t: Long("-1") }
}

看起来每个外部节点的问题原因可能各不相同,我现在不确定到底是网络配置、Operator参数还是MongoDB副本集自身的配置出了问题,有没有遇到过类似情况的朋友能给些排查方向或者解决方案?

备注:内容来源于stack exchange,提问作者Vanias Kopas

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.04.16 10:13:06