gpt4 book ai didi

kubernetes - NFS卷安装在具有错误IP的Kubernetes上超时?

转载 作者:行者123 更新时间:2023-12-02 12:34:42 26 4
gpt4 key购买 nike

97 Mounting command: systemd-run 98 Mounting arguments: --description=Kubernetes transient mount for /var/lib/kubelet/pods/06b9ae42-8e99-11e9-b888-a44c24184b19/volumes/kubernetes.io~nfs/nfs-data --scope -- mount -t nfs 10.100.155.82:/exports/www /var/lib/kubelet/pods/06b9ae42-8e99-11e9-b888-a44c24184b19/volumes/kubernetes.io~nfs/nfs-data 99 Output: Running scope as unit: run-r26f9da6c287846589bec8d059c33441d.scope 100 mount.nfs: Connection timed out

101 FailedMount Warning 2019-06-14T11:48:46Z 102 typo3-app-67b58d7657-cvqdg Pod Unable to mount volumes for pod "typo3-app-67b58d7657-cvqdg_default(1fb4c719-8e9a-11e9-b888-a44c24184b19)": timeout expired waiting for volumes to attach or mount for pod "default"/"typo3-app-67b58d7657-cvqdg". list of unmounted volumes=[nfs-data nfs-data-src]. list of unattached volumes=[nfs-data nfs-data-src default-token-lmtl4] FailedMount Warning 2019-06-14T11:49:04Z



奇怪的是我不知道从哪里获取 10.100.155.82?这是 ClusterIP的先前IP(与nfs服务有关)...
apiVersion: apps/v1
kind: Deployment
metadata:
name: typo3-app
labels:
app: typo3
spec:
replicas: 1
selector:
matchLabels:
app: typo3
template:
metadata:
labels:
app: typo3
spec:
containers:
- name: app
image: us.gcr.io/objit-chris/chrisjitit-typo3:v11
ports:
- containerPort: 80
volumeMounts:
- mountPath: /var/www/html-chrisjitit
name: nfs-data
- mountPath: /var/www/typo3_src-6.2.6
name: nfs-data-src
volumes:
- name: nfs-data
nfs:
# https://github.com/kubernetes/minikube/issues/3417
# server is not resolved using kube dns (so can't resolve to a service name - hence we need the IP)
#server: 10.11.250.37
server: 10.97.78.206
path: /exports/www
- name: nfs-data-src
nfs:
# https://github.com/kubernetes/minikube/issues/3417
# server is not resolved using kube dns (so can't resolve to a service name - hence we need the IP)
#server: 10.11.250.37
server: 10.97.78.206
path: /exports/www/typo3_src

超时/使用错误IP的原因可能是什么?

我尝试删除部署,更改了似乎仍然不起作用的名称,但几分钟后它起作用了……真的很奇怪吗?

再次遇到这个问题...:
 kubectl get pv
NAME CAPACITY ACCESS MODES RECLAIM POLICY STATUS CLAIM STORAGECLASS REASON AGE
nfs-data 10Gi RWO Retain Available 67m
pvc-f1353542-a8b1-11e9-bdf7-38ffa66115bc 10Gi RWO Delete Bound default/nfs-data standard 67m
kubectl get pvc
NAME STATUS VOLUME CAPACITY ACCESS MODES STORAGECLASS AGE
nfs-data Bound pvc-f1353542-a8b1-11e9-bdf7-38ffa66115bc 10Gi RWO standard 67m

最佳答案

它一直在使用旧的NFS IP。这是一个错误...:

Mounting arguments: --description=Kubernetes transient mount for /var/lib/kubelet/pods/9470ac17-a8b9-11e9-bdf7-38ffa66115bc/volumes/kubernetes.io~nfs/nfs-data-src --scope -- mount -t nfs 10.11.250.37:/exports/www/typo3_src /var/lib/kubelet/pods/9470ac17-a8b9-11e9-bdf7-38ffa66115bc/volumes/kubernetes.io~nfs/nfs-data-src
Output: Running scope as unit: run-ref2095cb52c94d0c87de5458c3b16733.scope
mount.nfs: Connection timed out

关于kubernetes - NFS卷安装在具有错误IP的Kubernetes上超时?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/56597634/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com