Kubernetes(k8s) 安装NFS SC提示 missing codepage or helper program, or other error

释放双眼,带上耳机,听听看~!

完整nfs provisioner报错如下

[root@k8s-01 ~]# kubectl describe pod -n nfs nfs-client-provisioner-856fb795b6-f98m2 
Name:           nfs-client-provisioner-856fb795b6-f98m2
Namespace:      nfs
Priority:       0
Node:           k8s-node2/192.168.31.14
Start Time:     Tue, 09 May 2023 21:38:47 +0800
Labels:         app=nfs-client-provisioner
                pod-template-hash=856fb795b6
Annotations:    <none>
Status:         Pending
IP:             
IPs:            <none>
Controlled By:  ReplicaSet/nfs-client-provisioner-856fb795b6
Containers:
  nfs-client-provisioner:
    Container ID:   
    Image:          quay.io/external_storage/nfs-client-provisioner:latest
    Image ID:       
    Port:           <none>
    Host Port:      <none>
    State:          Waiting
      Reason:       ContainerCreating
    Ready:          False
    Restart Count:  0
    Environment:
      PROVISIONER_NAME:  fuseim.pri/ifs
      NFS_SERVER:        192.168.31.101
      NFS_PATH:          /data
    Mounts:
      /persistentvolumes from nfs-client-root (rw)
      /var/run/secrets/kubernetes.io/serviceaccount from kube-api-access-27gmf (ro)
Conditions:
  Type              Status
  Initialized       True 
  Ready             False 
  ContainersReady   False 
  PodScheduled      True 
Volumes:
  nfs-client-root:
    Type:      NFS (an NFS mount that lasts the lifetime of a pod)
    Server:    192.168.31.101
    Path:      /data
    ReadOnly:  false
  kube-api-access-27gmf:
    Type:                    Projected (a volume that contains injected data from multiple sources)
    TokenExpirationSeconds:  3607
    ConfigMapName:           kube-root-ca.crt
    ConfigMapOptional:       <nil>
    DownwardAPI:             true
QoS Class:                   BestEffort
Node-Selectors:              <none>
Tolerations:                 node.kubernetes.io/not-ready:NoExecute op=Exists for 300s
                             node.kubernetes.io/unreachable:NoExecute op=Exists for 300s
Events:
  Type     Reason       Age               From               Message
  ----     ------       ----              ----               -------
  Normal   Scheduled    39s               default-scheduler  Successfully assigned nfs/nfs-client-provisioner-856fb795b6-f98m2 to k8s-node2
  Warning  FailedMount  8s (x7 over 39s)  kubelet            MountVolume.SetUp failed for volume "nfs-client-root" : mount failed: exit status 32
Mounting command: mount
Mounting arguments: -t nfs 192.168.31.101:/data /var/lib/kubelet/pods/40245756-8ce0-486e-b8b9-35927a09a0fb/volumes/kubernetes.io~nfs/nfs-client-root
Output: mount: wrong fs type, bad option, bad superblock on 192.168.31.101:/data,
       missing codepage or helper program, or other error
       (for several filesystems (e.g. nfs, cifs) you might
       need a /sbin/mount.<type> helper program)

       In some cases useful info is found in syslog - try
       dmesg | tail or so.

解决办法:

所有节点安装nfs utlis

[root@k8s-node1 ~]# yum install nfs-utils -y

查看pod状态

[root@k8s-01 ~]# kubectl get pod -n nfs -o wide
NAME                                      READY   STATUS    RESTARTS   AGE   IP           NODE        NOMINATED NODE   READINESS GATES
nfs-client-provisioner-856fb795b6-89r6f   1/1     Running   0          66s   10.244.4.5   k8s-node2   <none>           <none>

给TA打赏
共{{data.count}}人
人已打赏
报错锦集

Zookeeper集群节点异常 Unable to load database on disk java.io.IOException

2023-4-27 17:31:25

Kubernetes报错锦集

Kubernetes 删除namespace Terminating解决脚本

2023-5-23 10:50:30

0 条回复 A文章作者 M管理员
    暂无讨论,说说你的看法吧
个人中心
购物车
优惠劵
今日签到
有新私信 私信列表
搜索