ubuntu - k3s 获取 Kubernetes 服务器版本失败:获取 https://10.43.0.1:443/version?timeout=32s: dial tcp 10.43.0.1:443: connect: connection refused”
问题描述
我有一个奇怪的问题,我无法理解。在 ubuntu 服务器 18.04 LTS 上运行带有外部 mysql 数据库的 k3s 集群,预安装的所有 pod 都在运行。我将我的 k3s 集群连接到 GitLab,并想在我的集群上安装 Prometheus 和 Runners。但是,pod 安装失败并显示:
Error: looks like "https://gitlab-org.gitlab.io/cluster-integration/helm-stable-archive" is not a valid chart repository or cannot be reached: Get https://gitlab-org.gitlab.io/cluster-integration/helm-stable-archive/index.yaml: dial tcp: lookup gitlab-org.gitlab.io on 10.43.0.10:53: read udp 10.42.0.57:53088->10.43.0.10:53: read: connection refused
ufw 被禁用环顾四周我发现这可能是一个 iptables 问题,所以我尝试添加一些规则:
iptables -I INPUT 3 -s 10.42.0.0/16 -j ACCEPT
iptables -I INPUT 3 -d 10.42.0.0/16 -j ACCEPT
这没有帮助:
我也试过:
sudo iptables -A INPUT -s 10.42.0.0/16 -d <host_ip> -j ACCEPT
还尝试刷新重新安装 k3s 等。似乎没有任何效果。
解决方案
推荐阅读
- python - 我的服务器票务系统未运行 on_message(message)
- r - Drop Columns 已填写的列
- android - 如何使用 Zxing Android Embedded 扫描纯文本二维码
- haskell - 如何将多态函数应用于 Either 的两侧?
- excel - &“\”时的文件路径 - 运行时错误 76 找不到路径
- amazon-web-services - 向托管在 ec2 实例上的 Flask API 发送公共获取请求
- c - 如果我重新分配到更小的尺寸会发生什么?
- php - PHP代码将循环调用的图像转换为可点击的链接
- html - 更改 DT Shiny R 中过滤器标签的颜色
- python - 使用 Pandas 在 Python 中减去时间戳值