• DevOpsKubeSphere-3.x
  • 本地KubesphereAllInOne安装后,尝试开启DevOps时异常,提示Minio依赖的PV不成功

相关状态:

# kubectl get pod -A  -w
NAMESPACE                      NAME                                               READY   STATUS      RESTARTS   AGE
kube-system                    calico-kube-controllers-59d85c5c84-8n5rl           1/1     Running     1          2d22h
kube-system                    calico-node-g4kh9                                  1/1     Running     1          2d22h
kube-system                    coredns-74d59cc5c6-g852r                           1/1     Running     1          2d22h
kube-system                    coredns-74d59cc5c6-h27h4                           1/1     Running     1          2d22h
kube-system                    init-pvc-8e7cdf4b-add0-443b-80a6-a2dae0dc14e8      0/1     Completed   0          44h
kube-system                    kube-apiserver-node121                             1/1     Running     1          2d22h
kube-system                    kube-controller-manager-node121                    1/1     Running     18         2d22h
kube-system                    kube-proxy-88kgv                                   1/1     Running     2          2d22h
kube-system                    kube-scheduler-node121                             1/1     Running     18         2d22h
kube-system                    metrics-server-5ddd98b7f9-s2p44                    1/1     Running     35         2d22h
kube-system                    nodelocaldns-mc9z6                                 1/1     Running     1          2d22h
kube-system                    openebs-localpv-provisioner-84956ddb89-qbjzj       1/1     Running     0          44h
kube-system                    openebs-ndm-czvjd                                  1/1     Running     1          2d22h
kube-system                    openebs-ndm-operator-6896cbf7b8-zbjdq              1/1     Running     2          2d22h
kube-system                    snapshot-controller-0                              1/1     Running     1          2d22h
kubesphere-controls-system     default-http-backend-5d464dd566-72zxn              1/1     Running     2          2d22h
kubesphere-controls-system     kubectl-admin-6c9bd5b454-bcgzz                     1/1     Running     1          2d22h
kubesphere-monitoring-system   alertmanager-main-0                                2/2     Running     2          2d22h
kubesphere-monitoring-system   kube-state-metrics-5c466fc7b6-q5s7f                3/3     Running     3          2d22h
kubesphere-monitoring-system   node-exporter-mjc92                                2/2     Running     2          2d22h
kubesphere-monitoring-system   notification-manager-deployment-7ff95b7544-sddz8   1/1     Running     1          2d22h
kubesphere-monitoring-system   notification-manager-operator-5cbb58b756-bjsxx     2/2     Running     21         2d22h
kubesphere-monitoring-system   prometheus-k8s-0                                   3/3     Running     4          2d22h
kubesphere-monitoring-system   prometheus-operator-78c5cdbc8f-4llnc               2/2     Running     2          2d22h
kubesphere-system              ks-apiserver-8564486d6b-rstdn                      1/1     Running     3          2d22h
kubesphere-system              ks-console-fb4c655cf-ffln9                         1/1     Running     1          2d22h
kubesphere-system              ks-controller-manager-6fd8c5b5c5-9c2vm             1/1     Running     4          44h
kubesphere-system              ks-installer-85854b8c8-kb9j9                       1/1     Running     2          2d22h
kubesphere-system              minio-764b67f6fb-tpbgt                             0/1     Pending     0          2m37s
kubesphere-system              openldap-0                                         1/1     Running     2          2d22h
kubesphere-system              redis-6fd6c6d6f9-wzlmn                             1/1     Running     1          2d22h
kubectl get sc -A
NAME              PROVISIONER        RECLAIMPOLICY   VOLUMEBINDINGMODE      ALLOWVOLUMEEXPANSION   AGE
local (default)   openebs.io/local   Delete          WaitForFirstConsumer   false                  2d22h
# kubectl get node
NAME      STATUS   ROLES           AGE     VERSION
node121   Ready    master,worker   2d22h   v1.17.9

相关Eevent提示:

26m         Normal    Started                pod/ks-installer-85854b8c8-kb9j9                  Started container installer
44h         Warning   FailedScheduling       pod/minio-764b67f6fb-hmjkp                        0/1 nodes are available: 1 node(s) had taints that the pod didn't tolerate.
27m         Warning   FailedScheduling       pod/minio-764b67f6fb-hmjkp                        0/1 nodes are available: 1 node(s) had taints that the pod didn't tolerate.
6m50s       Warning   FailedScheduling       pod/minio-764b67f6fb-hmjkp                        Failed to bind volumes: timed out waiting for the condition
3m12s       Warning   FailedScheduling       pod/minio-764b67f6fb-hmjkp                        skip schedule deleting pod: kubesphere-system/minio-764b67f6fb-hmjkp
3m11s       Warning   FailedScheduling       pod/minio-764b67f6fb-hmjkp                        Failed to bind volumes: pod "kubesphere-system/minio-764b67f6fb-hmjkp" does not exist any more
3m12s       Normal    SuccessfulCreate       replicaset/minio-764b67f6fb                       Created pod: minio-764b67f6fb-tpbgt
43h         Normal    ExternalProvisioning   persistentvolumeclaim/minio                       waiting for a volume to be created, either by external provisioner "openebs.io/local" or manually created by system administrator
110s        Normal    ExternalProvisioning   persistentvolumeclaim/minio                       waiting for a volume to be created, either by external provisioner "openebs.io/local" or manually created by system administrator
10m         Normal    Provisioning           persistentvolumeclaim/minio                       External provisioner is provisioning volume for claim "kubesphere-system/minio"
10m         Warning   ProvisioningFailed     persistentvolumeclaim/minio                       failed to provision volume with StorageClass "local": pods "init-pvc-8e7cdf4b-add0-443b-80a6-a2dae0dc14e8" already exists
26m         Normal    SandboxChanged         pod/openldap-0                                    Pod sandbox changed, it will be killed and re-created.
26m         Normal    Pulled                 pod/openldap-0                                    Container image "osixia/openldap:1.3.0" already present on machine
26m         Normal    Created                pod/openldap-0                                    Created container openldap-ha
26m         Normal    Started                pod/openldap-0                                    Started container openldap-ha
26m         Normal    SandboxChanged         pod/redis-6fd6c6d6f9-wzlmn                        Pod sandbox changed, it will be killed and re-created.
26m         Normal    Pulled                 pod/redis-6fd6c6d6f9-wzlmn                        Container image "redis:5.0.5-alpine" already present on machine
26m         Normal    Created                pod/redis-6fd6c6d6f9-wzlmn                        Created container redis
26m         Normal    Started                pod/redis-6fd6c6d6f9-wzlmn                        Started container redis

    stoneshi-yunify

    # kubectl describe pvc -n kubesphere-system              minio
    Name:          minio
    Namespace:     kubesphere-system
    StorageClass:  local
    Status:        Pending
    Volume:        
    Labels:        app=minio
                   app.kubernetes.io/managed-by=Helm
                   chart=minio-2.5.16
                   heritage=Helm
                   release=ks-minio
    Annotations:   meta.helm.sh/release-name: ks-minio
                   meta.helm.sh/release-namespace: kubesphere-system
                   volume.beta.kubernetes.io/storage-provisioner: openebs.io/local
                   volume.kubernetes.io/selected-node: node121
    Finalizers:    [kubernetes.io/pvc-protection]
    Capacity:      
    Access Modes:  
    VolumeMode:    Filesystem
    Mounted By:    minio-764b67f6fb-tpbgt
    Events:
      Type     Reason                Age                   From                                                                                                Message
      ----     ------                ----                  ----                                                                                                -------
      Normal   Provisioning          11m (x12 over 110m)   openebs.io/local_openebs-localpv-provisioner-84956ddb89-qbjzj_30b3d718-a978-4551-b529-ad548908511a  External provisioner is provisioning volume for claim "kubesphere-system/minio"
      Warning  ProvisioningFailed    11m (x12 over 110m)   openebs.io/local_openebs-localpv-provisioner-84956ddb89-qbjzj_30b3d718-a978-4551-b529-ad548908511a  failed to provision volume with StorageClass "local": pods "init-pvc-8e7cdf4b-add0-443b-80a6-a2dae0dc14e8" already exists
      Normal   ExternalProvisioning  16s (x441 over 110m)  persistentvolume-controller                                                                         waiting for a volume to be created, either by external provisioner "openebs.io/local" or manually created by system administrator

    尝试手工删除 init pvc pod # kubectl delete pod --force --grace-period 0 -n kube-system init-pvc-8e7cdf4b-add0-443b-80a6-a2dae0dc14e8

    目前PVC 和 minio Pod正常,谢谢 stoneshi-yunify

    这是在本机vmare虚拟机下的kubekey安装版,之前在腾讯云服务器上自主安装kubernetes时,minio正常

    7 个月 后

    把配置备份(右上角的下载按钮),删除miniio pvc配置,从新建一个minio的配置,启动成功