How to fix ImagePullBackOff with Kubernetespod?

5/15/2019

I created a pod 5 hours ago.Now I have error:Pull Back Off These are events from describe pod

Events:
  Type     Reason       Age                      From               Message
  ----     ------       ----                     ----               -------
  Normal   Scheduled    4h51m                    default-scheduler  Successfully assigned default/nodehelloworld.example.com to minikube
  Normal   Pulling      4h49m (x4 over 4h51m)    kubelet, minikube  pulling image "milenkom/docker-demo"
  Warning  Failed       4h49m (x4 over 4h51m)    kubelet, minikube  Failed to pull image "milenkom/docker-demo": rpc error: code = Unknown desc = Error response from daemon: manifest for milenkom/docker-demo:latest not found
  Warning  Failed       4h49m (x4 over 4h51m)    kubelet, minikube  Error: ErrImagePull
  Normal   BackOff      4h49m (x6 over 4h51m)    kubelet, minikube  Back-off pulling image "milenkom/docker-demo"
  Warning  Failed       4h21m (x132 over 4h51m)  kubelet, minikube  Error: ImagePullBackOff
  Warning  FailedMount  5m13s                    kubelet, minikube  MountVolume.SetUp failed for volume "default-token-zpl2j" : couldn't propagate object cache: timed out waiting for the condition
  Normal   Pulling      3m34s (x4 over 5m9s)     kubelet, minikube  pulling image "milenkom/docker-demo"
  Warning  Failed       3m32s (x4 over 5m2s)     kubelet, minikube  Failed to pull image "milenkom/docker-demo": rpc error: code = Unknown desc = Error response from daemon: manifest for milenkom/docker-demo:latest not found
  Warning  Failed       3m32s (x4 over 5m2s)     kubelet, minikube  Error: ErrImagePull
  Normal   BackOff      3m5s (x6 over 5m1s)      kubelet, minikube  Back-off pulling image "milenkom/docker-demo"
  Warning  Failed       3m5s (x6 over 5m1s)      kubelet, minikube  Error: ImagePullBackOff

Images on my desktop

docker images
REPOSITORY                  TAG                 IMAGE ID            CREATED             SIZE
milenkom/docker-demo        tagname             08d27ff00255        6 hours ago         659MB

Following advices from Max and Shanica I made a mess when tagging

docker tag 08d27ff00255 docker-demo:latest

Works OK,but when I try docker push docker-demo:latest The push refers to repository [docker.io/library/docker-demo]

e892b52719ff: Preparing 
915b38bfb374: Preparing 
3f1416a1e6b9: Preparing 
e1da644611ce: Preparing 
d79093d63949: Preparing 
87cbe568afdd: Waiting 
787c930753b4: Waiting 
9f17712cba0b: Waiting 
223c0d04a137: Waiting 
fe4c16cbf7a4: Waiting 
denied: requested access to the resource is denied

although I am logged in

Output docker inspect image 08d27ff00255

[
    {
        "Id": "sha256:08d27ff0025581727ef548437fce875d670f9e31b373f00c2a2477f8effb9816",
        "RepoTags": [
            "docker-demo:latest",
            "milenkom/docker-demo:tagname"
        ],

Why does it fail assigning pod now?

-- Richard Rublev
kubernetes

1 Answer

5/15/2019
manifest for milenkom/docker-demo:latest not found

Looks like there's no latest tag in the image you want to pull: https://hub.docker.com/r/milenkom/docker-demo/tags.

Try some existing image.

UPD (based on question update):

  1. docker push milenkom/docker-demo:tagname
  2. update k8s pod to point to milenkom/docker-demo:tagname
-- Max Lobur
Source: StackOverflow