Docker context deadline exceeded

I am running docker in raspberry pi os (bulleye) 64 bit version, and I am having trouble getting docker to access the internet. I cannot pull any images, nor can I login using docker login. I checked online to seek help regarding this issue, and most of the answers were regarding setting DNS nameservers. So here’s what I have tried.

  1. Modified /etc/dhcpcd.conf to set static IP along with DNS 192.168.1.1(my router) and 8.8.8.8. I also tried bunch of other DNS servers, but nothing changed the outcome.
  2. restart daemon by sudo systemctl daemon-reload
  3. restart docker by sudo systemctl restart docker

Here is some of the log from journalctl -u docker:

Feb 08 15:43:36 MomNode dockerd[6421]: time=“2024-02-08T15:43:36.022987622-05:00” level=info msg=“Attempting next endpoint for pull after error: Get "https://registry-1.docker.io/v2/\”: context deadline exceeded"
Feb 08 15:43:36 MomNode dockerd[6421]: time=“2024-02-08T15:43:36.034712088-05:00” level=error msg=“Handler for POST /v1.44/images/create returned error: Get "https://registry-1.docker.io/v2/\”: context deadline exceeded"

Please assist further.

1 Like

Hi Sanmeel, did you ever figure this out? I’m having the same problem and nothing I do seems to be able to help.

Thanks!

Hi @dbraun0, I still haven’t figured out this issue with raspberry pi OS specifically, but I found a workaround by shifting to ubuntu server OS. Had to do a few tweaks to get peripherals working, but docker works just fine for that. Make sure to use 64bit version to get most peripherals working, if you’re into cameras and all. Let me know if it helps.

Best,
Sanmeel

Hi Sanmeel, I tried a couple more things, different versions of the raspberry pi os (32 and 64 bit) but no luck, I ended up also switching to ubuntu server like you did, and things are working flawlessly now. Thanks for the suggestion!

-Dagen