创建部署问题时,请参考下面模板,你提供的信息越多,越容易及时获得解答。如果未按模板创建问题,管理员有权关闭问题。
确保帖子格式清晰易读,用 markdown code block 语法格式化代码块。
你只花一分钟创建的问题,不能指望别人花上半个小时给你解答。

操作系统信息
物理机,Centos7.9,4C/16G

Kubernetes版本信息
kubectl version 命令执行结果贴在下方

容器运行时
docker version / crictl version / nerdctl version 结果贴在下方

[root@master1 kube-offline-install-packages]# crictl version

Version: 0.1.0

RuntimeName: containerd

RuntimeVersion: v1.7.13

RuntimeApiVersion: v1

KubeSphere版本信息
使用kk离线安装 KubeSpherev4.1.2版本 + Kubernetes 1.30.6

问题是什么

试过多次,每次安装都失败,报etcd启动失败:

16:03:31 CST message: [k8s-master01]

etcd health check failed: Failed to exec command: sudo -E /bin/bash -c “export ETCDCTL_API=2;export ETCDCTL_CERT_FILE=‘/etc/ssl/etcd/ssl/admin-k8s-master01.pem’;export ETCDCTL_KEY_FILE=‘/etc/ssl/etcd/ssl/admin-k8s-master01-key.pem’;export ETCDCTL_CA_FILE=‘/etc/ssl/etcd/ssl/ca.pem’;/usr/local/bin/etcdctl –endpoints=https://10.6.2.70:2379,https://10.6.2.74:2379 cluster-health | grep -q ‘cluster is healthy’”

Error: client: etcd cluster is unavailable or misconfigured; error #0: dial tcp 10.6.2.70:2379: connect: connection refused

; error #1: dial tcp 10.6.2.74:2379: connect: no route to host

error #0: dial tcp 10.6.2.70:2379: connect: connection refused

error #1: dial tcp 10.6.2.74:2379: connect: no route to host: Process exited with status 1

16:03:31 CST retry: [k8s-master01]

16:03:36 CST message: [k8s-master02]

etcd health check failed: Failed to exec command: sudo -E /bin/bash -c “export ETCDCTL_API=2;export ETCDCTL_CERT_FILE=‘/etc/ssl/etcd/ssl/admin-k8s-master02.pem’;export ETCDCTL_KEY_FILE=‘/etc/ssl/etcd/ssl/admin-k8s-master02-key.pem’;export ETCDCTL_CA_FILE=‘/etc/ssl/etcd/ssl/ca.pem’;/usr/local/bin/etcdctl –endpoints=https://10.6.2.70:2379,https://10.6.2.74:2379 cluster-health | grep -q ‘cluster is healthy’”

Error: client: etcd cluster is unavailable or misconfigured; error #0: dial tcp 10.6.2.74:2379: connect: connection refused

; error #1: dial tcp 10.6.2.70:2379: connect: no route to host

error #0: dial tcp 10.6.2.74:2379: connect: connection refused

error #1: dial tcp 10.6.2.70:2379: connect: no route to host: Process exited with status 1

    sydney

    你这些节点的 ip 地址是配置的 eip,不是机器网卡的 ip ?

    这个就是网卡的地址:

    eth0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500

        inet 10.6.2.70  netmask 255.255.255.0  broadcast 10.6.2.255
    
        inet6 fe80::216:3eff:fe0b:4136  prefixlen 64  scopeid 0x20<link>
    
        ether 00:16:3e:0b:41:36  txqueuelen 1000  (Ethernet)
    
        RX packets 1773649  bytes 158940104 (151.5 MiB)
    
        RX errors 0  dropped 0  overruns 0  frame 0
    
        TX packets 204174  bytes 735305038 (701.2 MiB)
    
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

    lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536

        inet 127.0.0.1  netmask 255.0.0.0
    
        inet6 ::1  prefixlen 128  scopeid 0x10<host>
    
        loop  txqueuelen 1000  (Local Loopback)
    
        RX packets 7629  bytes 1017617 (993.7 KiB)
    
        RX errors 0  dropped 0  overruns 0  frame 0
    
        TX packets 7629  bytes 1017617 (993.7 KiB)
    
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

    virbr0: flags=4099<UP,BROADCAST,MULTICAST> mtu 1500

        inet 192.168.122.1  netmask 255.255.255.0  broadcast 192.168.122.255
    
        ether 52:54:00:3c:cd:81  txqueuelen 1000  (Ethernet)
    
        RX packets 0  bytes 0 (0.0 B)
    
        RX errors 0  dropped 0  overruns 0  frame 0
    
        TX packets 0  bytes 0 (0.0 B)
    
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

    那可以检查下节点之间是不是有防火墙或者安全组

    20 天 后