移除集群

  1. 在rancher UI移除集群后,该集群的cattle-system命名空间一直处于terminating,如下图

image.png
解决方法参考:https://blog.csdn.net/qq_37279279/article/details/107961464

  1. kubectl patch namespace cattle-system -p '{"metadata":{"finalizers":[]}}' --type='merge' -n cattle-system

image.png

导入集群

  1. 导入新集群,一直处于Pending,需kubectl edit deploy/cattle-cluster-agent -n cattle-system,与volumes同级

       hostAliases:
       - hostnames:
         - rancher.test.com
         ip: 10.222.102.138
    #      volumes:
    
  2. 待补充

rancher 执行命令行窗口自动关闭

参考:
https://github.com/rancher/rancher/issues/6192
https://github.com/rancher/rancher/issues/2186

设置haproxy.conf

timeout client 1h
timeout server 1h
##如果修改了haproxy.conf,reload haproxy gracefully
docker kill -s HUP my-running-haproxy