Unable to mount volumes for pod "nginx-

发布时间:2020-06-14 03:58:51 作者:liguoyuan
来源:网络 阅读:4603

Events: Type Reason Age From Message


Warning FailedMount 6m (x25 over 1h) kubelet, 10.130.33.13 Unable to mount volumes for pod "nginx-hello-deployment-6f9f4d7bcc-lbt2n_chenqiang-pv-test(7b0fcbd3-7382-11e8-80b5-74eacb7559f1)": timeout expired waiting for volumes to attach/mount for pod "chenqiang-pv-test"/"nginx-hello-deployment-6f9f4d7bcc-lbt2n". list of unattached/unmounted volumes=[nfs]
Warning FailedMount 12s (x39 over 1h) kubelet, 10.130.33.13 (combined from similar events): MountVolume.SetUp failed for volume "nfs-pv" : mount failed: exit status 32 Mounting command: systemd-run Mounting arguments: --description=Kubernetes transient mount for /var/lib/kubelet/pods/7b0fcbd3-7382-11e8-80b5-74eacb7559f1/volumes/kubernetes.io~nfs/nfs-pv --scope -- mount -t nfs 10.130.44.20:/test/mysql-nfs01 /var/lib/kubelet/pods/7b0fcbd3-7382-11e8-80b5-74eacb7559f1/volumes/kubernetes.io~nfs/nfs-pv Output: Running scope as unit run-11918.scope. mount: wrong fs type, bad option, bad superblock on 10.130.44.20:/test/mysql-nfs01, 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.

根据错误提示,查看/sbin/mount.<type>文件,果然发现没有/sbin/mount.nfs的文件,安装 nfs-utils 即可

解决办法:

apt-get install nfs-common

或者

yum install nfs-utils

安装之后,/sbin/ 下面多了几个 mount 文件,比如 mount.nfs 和 mount.nfs4等:

[appuser@chenqiang-dev]# cat /sbin/mo

再次 kubectl get po 试下,发现起来了

推荐阅读:
  1. WINDOWS2016想要使用NFS挂载,但是没有NFS服务,无法使用mount命令
  2. NFS自动mount的使用

免责声明:本站发布的内容(图片、视频和文字)以原创、转载和分享为主,文章观点不代表本网站立场,如果涉及侵权请联系站长邮箱:is@yisu.com进行举报,并提供相关证据,一经查实,将立刻删除涉嫌侵权内容。

nfs k8s fo

上一篇:PC软件加密方案

下一篇:揭密 Vue 的双向绑定

相关阅读

您好,登录后才能下订单哦!

密码登录
登录注册
其他方式登录
点击 登录注册 即表示同意《亿速云用户服务条款》