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

新手想在自己本机win10上装个kubesphere玩一下,已装好Docker Desktop及kubernetes,第一次装好kubesphere后,能够正常打开localhost:30880并用admin/P@88w0rd登录,重启电脑后就再也打不开登录页面了。请大神帮忙看看

操作系统信息
例如:虚拟机/物理机,Centos7.5/Ubuntu18.04,4C/8G

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

Client Version: version.Info{Major:“1”, Minor:“22”, GitVersion:“v1.22.5”, GitCommit:“5c99e2ac2ff9a3c549d9ca665e7bc05a3e18f07e”, GitTreeState:“clean”, BuildDate:“2021-12-16T08:38:33Z”, GoVersion:“go1.16.12”, Compiler:“gc”, Platform:"

windows/amd64″}

Server Version: version.Info{Major:“1”, Minor:“22”, GitVersion:“v1.22.5”, GitCommit:“5c99e2ac2ff9a3c549d9ca665e7bc05a3e18f07e”, GitTreeState:“clean”, BuildDate:“2021-12-16T08:32:32Z”, GoVersion:“go1.16.12”, Compiler:“gc”, Platform:"

linux/amd64″}

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

Client:

Cloud integration: v1.0.22

Version: 20.10.13

API version: 1.41

Go version: go1.16.15

Git commit: a224086

Built: Thu Mar 10 14:13:04 2022

OS/Arch: windows/amd64

Context: default

Experimental: true

Server: Docker Desktop 4.6.1 (76265)

Engine:

Version: 20.10.13

API version: 1.41 (minimum version 1.12)

Go version: go1.16.15

Git commit: 906f57f

Built: Thu Mar 10 14:06:05 2022

OS/Arch: linux/amd64

Experimental: false

containerd:

Version: 1.5.10

GitCommit: 2a1d4dbdb2a1030dc5b01e96fb110a9d9f150ecc

runc:

Version: 1.0.3

GitCommit: v1.0.3-0-gf46b6ba

docker-init:

Version: 0.19.0

GitCommit: de40ad0

KubeSphere版本信息
例如:v2.1.1/v3.0.0。离线安装还是在线安装。在已有K8s上安装还是使用kk安装。

按这个装的,上面介绍3.2.1:

https://kubesphere.com.cn/docs/quick-start/minimal-kubesphere-on-k8s/

问题是什么
报错日志是什么,最好有截图。

不知是否跟这个node-exporter的CrashLoopBackOff有关?

执行kubectl describe pod -n kubesphere-monitoring-system node-exporter-99cp5如下:

Name: node-exporter-99cp5

Namespace: kubesphere-monitoring-system

Priority: 0

Node: docker-desktop/192.168.65.4

Start Time: Wed, 20 Apr 2022 17:51:05 +0800

Labels: app.kubernetes.io/name=node-exporter

          app.kubernetes.io/version=v0.18.1

          controller-revision-hash=67d5cccfff

          pod-template-generation=1

Annotations: <none>

Status: Running

IP: 192.168.65.4

IPs:

IP: 192.168.65.4

Controlled By: DaemonSet/node-exporter

Containers:

node-exporter:

Container ID:  docker://170a27ac31dc74d54d4d01b73fbffe983542050d2ef181051a64dedc87ebb035

Image:         prom/node-exporter:v0.18.1

Image ID:      docker-pullable://prom/node-exporter@sha256:a2f29256e53cc3e0b64d7a472512600b2e9410347d53cdc85b49f659c17e02ee

Port:          <none>

Host Port:     <none>

Args:

  --web.listen-address=127.0.0.1:9100

  --path.procfs=/host/proc

  --path.sysfs=/host/sys

  --path.rootfs=/host/root

  --no-collector.wifi

  --no-collector.hwmon

  --collector.filesystem.ignored-mount-points=^/(dev|proc|sys|var/lib/docker/.+)($|/)

  --collector.filesystem.ignored-fs-types=^(autofs|binfmt_misc|cgroup|configfs|debugfs|devpts|devtmpfs|fusectl|hugetlbfs|mqueue|overlay|proc|procfs|pstore|rpc_pipefs|securityfs|sysfs|tracefs)$

State:          Waiting

  Reason:       RunContainerError

Last State:     Terminated

  Reason:       ContainerCannotRun

  Message:      path / is mounted on / but it is not a shared or slave mount

  Exit Code:    128

  Started:      Fri, 20 May 2022 15:10:53 +0800

  Finished:     Fri, 20 May 2022 15:10:53 +0800

Ready:          False

Restart Count:  3855

Limits:

  cpu:     1

  memory:  500Mi

Requests:

  cpu:        102m

  memory:     180Mi

Environment:  <none>

Mounts:

  /host/proc from proc (ro)

  /host/root from root (ro)

  /host/sys from sys (ro)

  /var/run/secrets/kubernetes.io/serviceaccount from kube-api-access-fj4vn (ro)

kube-rbac-proxy:

Container ID:  docker://6badb5dd9ed3352e15e9f4dfe4f0256ce6c38fd81260428e7a62df7f65e44117

Image:         kubesphere/kube-rbac-proxy:v0.8.0

Image ID:      docker-pullable://kubesphere/kube-rbac-proxy@sha256:db06cc4c084dd0253134f156dddaaf53ef1c3fb3cc809e5d81711baa4029ea4c

Port:          9100/TCP

Host Port:     9100/TCP

Args:

  --logtostderr

  --secure-listen-address=[$(IP)]:9100

  --tls-cipher-suites=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256,TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256,TLS_RSA_WITH_AES_128_CBC_SHA256,TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256,TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256

  --upstream=http://127.0.0.1:9100/

State:          Running

  Started:      Fri, 20 May 2022 14:19:20 +0800

Last State:     Terminated

  Reason:       Error

  Exit Code:    255

  Started:      Fri, 20 May 2022 08:32:43 +0800

  Finished:     Fri, 20 May 2022 14:18:48 +0800

Ready:          True

Restart Count:  36

Limits:

  cpu:     1

  memory:  100Mi

Requests:

  cpu:     10m

  memory:  20Mi

Environment:

  IP:   (v1:status.podIP)

Mounts:

  /var/run/secrets/kubernetes.io/serviceaccount from kube-api-access-fj4vn (ro)

Conditions:

Type Status

Initialized True

Ready False

ContainersReady False

PodScheduled True

Volumes:

proc:

Type:          HostPath (bare host directory volume)

Path:          /proc

HostPathType:

sys:

Type:          HostPath (bare host directory volume)

Path:          /sys

HostPathType:

root:

Type:          HostPath (bare host directory volume)

Path:          /

HostPathType:

kube-api-access-fj4vn:

Type:                    Projected (a volume that contains injected data from multiple sources)

TokenExpirationSeconds:  3607

ConfigMapName:           kube-root-ca.crt

ConfigMapOptional:       <nil>

DownwardAPI:             true

QoS Class: Burstable

Node-Selectors: kubernetes.io/os=linux

Tolerations: op=Exists

                         node.kubernetes.io/disk-pressure:NoSchedule op=Exists

                         node.kubernetes.io/memory-pressure:NoSchedule op=Exists

                         node.kubernetes.io/network-unavailable:NoSchedule op=Exists

                         node.kubernetes.io/not-ready:NoExecute op=Exists

                         node.kubernetes.io/pid-pressure:NoSchedule op=Exists

                         node.kubernetes.io/unreachable:NoExecute op=Exists

                         node.kubernetes.io/unschedulable:NoSchedule op=Exists

Events:

Type Reason Age From Message

Warning BackOff 3h18m (x898 over 6h38m) kubelet Back-off restarting failed container

Normal SandboxChanged 51m kubelet Pod sandbox changed, it will be killed and re-created.

Normal Pulled 51m kubelet Container image “kubesphere/kube-rbac-proxy:v0.8.0” already present on machine

Normal Created 51m kubelet Created container kube-rbac-proxy

Normal Started 51m kubelet Started container kube-rbac-proxy

Normal Pulled 50m (x4 over 51m) kubelet Container image “prom/node-exporter:v0.18.1” already present on machine

Normal Created 50m (x4 over 51m) kubelet Created container node-exporter

Warning Failed 50m (x4 over 51m) kubelet Error: failed to start container “node-exporter”: Error response from daemon: path / is mounted on / but it is not a shared or slave mount

Warning BackOff 99s (x227 over 51m) kubelet Back-off restarting failed container

13 天 后
7 个月 后

我的情况比你差多了,我安装完了连登陆都没法登陆,也是node没起来,俩节点就启动了一个

你的问题到现在解决了吗?

    Warning Failed 50m (x4 over 51m) kubelet Error: failed to start container “node-exporter”: Error response from daemon: path / is mounted on / but it is not a shared or slave mount

    这里看是存储挂载问题,详细可以参考这个:
    https://stackoverflow.com/questions/70556984/kubernetes-node-exporter-container-is-not-working-it-shows-this-error-message

      DehaoCheng 我没有看懂这篇文章,因为我安装kubesphere,无法安装这个守护守护进程集,报的错是一样的,但是这篇文章貌似说普罗米修斯的问题,我按照对应的教程无法操作

      DehaoCheng 看到我最后一个图了吗?我怀疑是找不到/目录没法做宿主机的绑定,我把/目录删了就不报错了,组件能正常运行,但是我不知道会不会出现其他问题,就这样吧也算解决了