k8s,RabbitMQ和对等发现 [英] k8s, RabbitMQ, and Peer Discovery

查看:457
本文介绍了k8s,RabbitMQ和对等发现的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们正在尝试从使用Helm运行RabbitMQ图表的实例helm/charts/stable/rabbit 项目.我让它运行完美,但是随后我不得不重新启动k8s进行维护.现在,我们完全无法以任何形式启动RabbitMQ图表.我什至不尝试使用任何变量(即仅默认值)运行图表.

We are trying to run an instance of the RabbitMQ chart with Helm from the helm/charts/stable/rabbit project. I had it running perfect but then I had to restart k8s for some maintenance. Now we are completely unable to launch the RabbitMQ chart in any way shape or form. I am not even trying to run the chart with any variables, i.e. just the default values.

这是我正在做的所有事情:

Here is all I am doing:

helm install stable/rabbitmq

我已经确认我可以直接在与Docker for Desktop一起运行的本地k8上运行默认权限.当我们在共享的k8上运行兔子图时,与在桌面上以及在重新启动之前所做的完全相同时,会引发以下错误:

I have confirmed I can simply run the default right on my local k8s which I'm running with Docker for Desktop. When we run the rabbit chart on our shared k8s the exact same way as on desktop and what we did before the restart, the following error is thrown:

Failed to get nodes from k8s - 503

我也在Helm图表仓库中发布了一个问题. 点击此处查看有关Github的问题.

I have also posted an issue on the Helm charts repo as well. Click here to see the issue on Github.

我们怀疑DNS,但尚无法确认.令人沮丧的是,重新启动后,我们安装的所有其他图表都完美地重新启动,但Rabbit根本无法启动.

We are suspecting the DNS but are unable to confirm anything yet. What is very frustrating is after the restart every single other chart we installed restarted perfectly except Rabbit which now will not start at all.

任何人都知道我该怎么做才能使Rabbits对等发现工作正常?重启k8s后,有人看到过这样的问题吗?

Anyone know what I could do to get Rabbits peer discovery to work? Anyone seen issue like this after restarting k8s?

推荐答案

所以我实际上让Rabbit运行了.原来我的问题是k8s对等发现无法通过默认端口443连接,并且我不得不使用外部端口6443,因为kubernetes.default.svc.cluster.local解析为公共端口并且找不到内部端口,所以是的,我们的配置也被搞砸了.

So I actually got rabbit to run. Turns out my issue was the k8s peer discovery could not connect over the default port 443 and I had to use the external port 6443 because kubernetes.default.svc.cluster.local resolved to the public port and could not find the internal, so yeah our config is messed up too.

我花了一段时间才意识到,当我用helm install . -f server-values.yaml覆盖下面的变量时,下面的变量没有被覆盖.

It took me a while to realize the variable below was not overriding when I overrode it with helm install . -f server-values.yaml.

rabbitmq:
  configuration: |-
    ## Clustering
    cluster_formation.peer_discovery_backend  = rabbit_peer_discovery_k8s
    cluster_formation.k8s.host = kubernetes.default.svc.cluster.local
    cluster_formation.k8s.port = 6443
    cluster_formation.node_cleanup.interval = 10
    cluster_formation.node_cleanup.only_log_warning = true
    cluster_partition_handling = autoheal
    # queue master locator
    queue_master_locator=min-masters
    # enable guest user
    loopback_users.guest = false

我必须将cluster_formation.k8s.port = 6443添加到主values.yaml文件中,而不是我自己的文件.一旦在values.yaml中专门更改了端口,rabbit就开始启动.

I had to add cluster_formation.k8s.port = 6443 to the main values.yaml file instead of my own. Once the port was changed specifically in the values.yaml, rabbit started right up.

这篇关于k8s,RabbitMQ和对等发现的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆