【问题标题】:kubernate microk8s dashboard-proxy timed out waiting for the condition on deployments/kubernetes-dashboardkubernetes microk8s dashboard-proxy 超时等待部署/kubernetes-dashboard 上的条件
【发布时间】:2021-01-11 00:48:14
【问题描述】:

我在启动集群仪表板时遇到了超时问题

   microk8s dashboard-proxy

这个问题在我的 kubernate 集群中反复出现。我真的不知道它的原因。

   error: timed out waiting for the condition on deployments/kubernetes-dashboard
   Traceback (most recent call last):
   File "/snap/microk8s/1609/scripts/wrappers/dashboard-proxy.py", line 50, in <module>
    dashboard_proxy()
    File "/snap/microk8s/1609/scripts/wrappers/dashboard-proxy.py", line 13, in dashboard_proxy
    check_output(command)
    File "/snap/microk8s/1609/usr/lib/python3.5/subprocess.py", line 626, in check_output
**kwargs).stdout
   File "/snap/microk8s/1609/usr/lib/python3.5/subprocess.py", line 708, in run
output=stdout, stderr=stderr)
  subprocess.CalledProcessError: Command '['microk8s.kubectl', '-n', 'kube-system', 'wait', '--timeout=240s', 'deployment', 'kubernetes-dashboard', '--for', 'condition=available']' returned  non-zero exit status 1

【问题讨论】:

    标签: kubernetes microk8s


    【解决方案1】:

    我正在使用 microk8s 在 vagrant 机器(Centos)上运行一个 kubernate 集群。这个问题可能是由许多原因引起的。下面是其中的一些;

    • 内存泄漏

    修复:您需要在 vagrant 机器设置中增加内存

    • 安装 microk8s 时出了点问题

    修复:删除 microk8s 并重新安装。就我而言,我使用 snap 来安装它。我就是这样做的

       snap remove microk8s --purge
       snap install microk8s --classic --channel=1.18/stable
    
    • 有时您需要终止该进程并重新启动您的 vagrant 机器。就我而言,我做到了

       lsof -Pi:10443 where 10443 on which my dashboard is running
       kill -9 xxxx where xxxx is the PID retrieved from the previous command
      

    【讨论】:

      猜你喜欢
      • 2018-05-21
      • 2019-08-04
      • 2018-09-02
      • 1970-01-01
      • 2022-01-20
      • 2020-07-13
      • 1970-01-01
      • 1970-01-01
      • 2021-11-29
      相关资源
      最近更新 更多