The Pod Status or Flannel Plugin Status Is CrashLoopBackoff
Symptom
After Kubernetes is deployed, the pod status or the flannel plugin status switches between CrashLoopBackoff and Running.
Figure 1 Pod status
Figure 2 Flannel plugin status
Key Process and Cause Analysis
The memory is insufficient.
Conclusion and Solution
- Modify the kube-flannel.yml and nginx.yml configuration files to increase the memory size under resources. For example, if the memory size is changed from 50Mi to 100Mi, the value of memory under limits must be increased as required.
- Run the apply command again to reinstall the corresponding plugin and application.
kubectl apply -f kube-flannel.yml kubectl apply -f nginx.yml
Parent topic: Docker & Kubernetes