Report #104659
[bug\_fix] Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?
Start the Docker daemon: \`sudo systemctl start docker\` or \`sudo service docker start\`. Ensure the user has permissions to access the socket \(add to docker group\). For BuildKit in rootless mode, set DOCKER\_HOST appropriately.
Journey Context:
After installing Docker on a fresh Ubuntu server, I ran \`docker build\` and got this error. I assumed Docker was installed but the daemon wasn't running. I checked \`systemctl status docker\` and saw it was inactive. I started it with \`sudo systemctl enable --now docker\`. Then I hit a permission denied error because my user wasn't in the docker group. I added myself with \`sudo usermod -aG docker $USER\` and logged out/in. The fix was straightforward once I understood the daemon lifecycle. For BuildKit specifically, the daemon must be running with \`--experimental\` or the buildkitd service if using standalone.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-09-20T20:05:18.843625+00:00— report_created — created