an imagePullBackOff in the POD with the python and redis containers
ImagePullBackOff means that Kubernetes was unable to pull the image defined in your Pod spec. You can get more details about this error by running kubectl describe pod <podname> and looking at the Events: field, or by running kubectl get events and looking for events associated with your pod.
Common causes for this error include:
- An invalid image name
- Hitting Docker Hub rate limits
- Failure to authenticate to a remote registry
For example, if I intentionally create a Pod with an invalid image name, I see it go into ImagePullBackOff state:
$ kubectl get pod
NAME READY STATUS RESTARTS AGE
demo-server 0/1 ImagePullBackOff 0 96s
And running kubectl describe pod demo-server shows:
.
.
.
Events:
Type Reason Age From Message
---- ------ ---- ---- -------
Normal Scheduled 49s default-scheduler Successfully assigned lars-sandbox/demo-server to wrk-89
Normal AddedInterface 48s multus Add eth0 [10.131.10.85/23] from openshift-sdn
Normal BackOff 22s (x2 over 47s) kubelet Back-off pulling image "docker.io/alpinelinux/darkhttpdz"
Warning Failed 22s (x2 over 47s) kubelet Error: ImagePullBackOff
Normal Pulling 7s (x3 over 48s) kubelet Pulling image "docker.io/alpinelinux/darkhttpdz"
Warning Failed 7s (x3 over 48s) kubelet Failed to pull image "docker.io/alpinelinux/darkhttpdz": rpc error: code = Unknown desc = reading manifest latest in docker.io/alpinelinux/darkhttpdz: requested access to the resource is denied
Warning Failed 7s (x3 over 48s) kubelet Error: ErrImagePull
a CrashLoopBackOff in the POD with the mysql container
CrashLoopBackOff means that Kubernetes was able to successfully pull the image and start your container, but then the container process exited with an error.
You can generally get more information about this problem by looking at the output of kubectl logs <pod>. If your pod has multiple containers, you can specify --all-containers=true or you can specify a particular container with -c <container>. In some cases (e.g. if your Pod spec attempts to run a command that doesn't exist), you will also find useful information in kubectl describe/kubectl get events as described in the previous section.
Typical reasons for CrashLoopBackOff include:
- Passing an invalid configuration to your application
- Specifying an invalid command in your Pod spec