apache / rocketmq-operator

Apache RocketMQ Operator
https://rocketmq.apache.org/
Apache License 2.0
308 stars 126 forks source link

broker使用hostNetwork: true,但是注册到name-service上的IP还是pod CIDR段的IP #202

Closed yylstudy closed 5 months ago

yylstudy commented 6 months ago
  1. Please describe the issue you observed:

broker使用hostNetwork: true,但是注册到name-service上的IP还是pod CIDR段的IP broker配置如下 image broker启动后ip也为节点IP image 查看dashboard上的broker 仍然为pod的CIDR段IP image

broker日志也是CIDR段的IP image

  1. Please tell us about your environment: k8s:1.23.6 网络插件:cilium rocketmq-operator:采用helm部署,版本为0.3.0 broker镜像版本apacherocketmq/rocketmq-broker:4.5.0-alpine-operator-0.3.0

请问下为什么会出现这个问题呢,是不是和broker的镜像有关系,谢谢。

shangjin92 commented 6 months ago

Yes, it may be related to the broker image, where you need to set the brokerIP1 parameter. Please see https://rocketmq.apache.org/docs/4.x/parameterConfiguration/02server/

image

yylstudy commented 6 months ago

这个不能设置brokerIP1吧,在broker hostNetwork为true的情况下,如果获取到的是节点IP,那么外部就能访问到了