kubernetes:在 Windows 11 上找不到 PersistentVolume 主机路径。
kubectl 描述 pv/pvc-4a7bc0ff-9195-4f2f-bd70-9dfd1f8cd065
Name: pvc-4a7bc0ff-9195-4f2f-bd70-9dfd1f8cd065
Labels: <none>
Annotations: docker.io/hostpath: /var/lib/k8s-pvs/my-pv-claim/pvc-4a7bc0ff-9195-4f2f-bd70-9dfd1f8cd065
pv.kubernetes.io/provisioned-by: docker.io/hostpath
Finalizers: [kubernetes.io/pv-protection]
StorageClass: hostpath
Status: Bound
Claim: default/my-pv-claim
Reclaim Policy: Delete
Access Modes: RWO
VolumeMode: Filesystem
Capacity: 20Gi
Node Affinity: <none>
Message:
Source:
Type: HostPath (bare host directory volume)
Path: /var/lib/k8s-pvs/my-pv-claim/pvc-4a7bc0ff-9195-4f2f-bd70-9dfd1f8cd065
HostPathType:
Events: <none>
但是在 Windows 11 WSL 上找不到路径 /var/lib/k8s-pvs/my-pv-claim/pvc-4a7bc0ff-9195-4f2f-bd70-9dfd1f8cd065。