MountVolume.SetUp failed for volume "mysql-pv" : CephFS: mount failed: mount failed: exit status 32 Mounting command: systemd-run Mounting arguments: --description=Kubernetes transient mount for /var/lib/kubelet/pods/87e91420-a3bb-4c9d-8dfa-50f20881645d/volumes/kubernetes.io~cephfs/mysql-pv --scope -- mount -t ceph -o <masked>,<masked> 10.2.0.151:6789:/mysql8 /var/lib/kubelet/pods/87e91420-a3bb-4c9d-8dfa-50f20881645d/volumes/kubernetes.io~cephfs/mysql-pv Output: Running scope as unit run-11819.scope. mount: 特殊设备 10.2.0.151:6789:/mysql8 不存在
apiVersion: v1
kind: PersistentVolume
metadata:
name: mysql-pv
spec:
capacity:
storage: 100Gi
cephfs:
monitors:
- 10.2.0.151:6789
path: /mysql8
user: admin
secretRef:
name: ceph-secret
fsType: ext4
readOnly: false
accessModes:
- ReadWriteOnce
persistentVolumeReclaimPolicy: Delete
1
vhwwls 2022-11-17 01:54:30 +08:00
非 csi 方式使用 cephfs 需要预先创建好 cephfs 上对应的 path ,检查一下你的 cephfs 根目录下是否有 mysql8 这个目录
|
2
cookgo OP @vhwwls 已经手动创建了 mysql8 路径,但是我看日志打印的 mount -t ceph 错误,感觉是这个版本 kunernetes 版本的问题
|