老师,你好
无法启动ingress-nginx,主节点状态:
[root@server01 ingress-nginx]# kubectl get all -n ingress-nginx
NAME READY STATUS RESTARTS AGE
pod/default-http-backend-5c9bb94849-cbtb2 1/1 Running 0 10m
pod/nginx-ingress-controller-5d5dc7d9dd-lgt6d 0/1 CrashLoopBackOff 6 10m
NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
service/default-http-backend ClusterIP 10.99.17.59 <none> 80/TCP 10m
NAME READY UP-TO-DATE AVAILABLE AGE
deployment.apps/default-http-backend 1/1 1 1 10m
deployment.apps/nginx-ingress-controller 0/1 1 0 10m
去从节点上面查看系统日志:
Error syncing pod cffc32c6-a0a8-11ea-bcc6-080027a4aa8b (“nginx-ingress-controller-5d5dc7d9dd-lgt6d_ingress-nginx(cffc32c6-a0a8-11ea-bcc6-080027a4aa8b)”), skipping: failed to “StartContainer” for “nginx-ingress-controller” with CrashLoopBackOff: “Back-off 5m0s restarting failed container=nginx-ingress-controller pod=nginx-ingress-controller-5d5dc7d9dd-lgt6d_ingress-nginx(cffc32c6-a0a8-11ea-bcc6-080027a4aa8b)”
查看pods日志:
kubectl logs nginx-ingress-controller-5d5dc7d9dd-lgt6d -n ingress-nginx
I0528 06:13:26.011841 6 main.go:191] Creating API client for https://10.96.0.1:443
I0528 06:13:26.020737 6 main.go:235] Running in Kubernetes cluster version v1.14 (v1.14.0) - git (clean) commit 641856db18352033a0d96dbc99153fa3b27298e5 - platform linux/amd64
F0528 06:13:26.020841 6 main.go:98] No service with name /default-http-backend found: an empty namespace may not be set when a resource name is provided
再之后不知道从哪个方向查了,从节点的系统日志不是很明确,请老师给指条明路。