Docker Community Forums

Share and learn in the Docker community.

Failed with status: 401 Unauthorized

(Akamez) #1


I am getting the following error on the logs when trying to run/pull hello-world

msg="Handler for POST /v1.23/containers/create returned error: No such image: hello-world:latest"
msg="Attempting next endpoint for pull after error: unauthorized: authentication required"
msg="unable to get remote tags: Could not reach any registry endpoint"
msg="Not continuing with pull after error: Could not reach any registry endpoint"

I also get error messages when trying to run docker login

Handler for POST /v1.23/auth returned error: login attempt to https :// failed with status: 401 Unauthorized

I am using a working cntlm proxy (I tried without it too), and wget curl etc work ok

# curl https_://
[{"checksum": "", "id": "d59cd4c39e502ebb7eabe6b49eb0b5e19d38dede67540c51a27b5426c0976f4e"}, {"checksum": "", "id": "f1d956dc5945042a7aa18067346f1c2f1b47f39590a53f23e009600d5a9b.....

# cat /root/.curlrc 

also we have SSL certificate intercept in our proxy, but the certificate is installed on the system (and accepted as seen in the curl test)

Any ideas will be appreciated!

# docker info
Containers: 0
 Running: 0
 Paused: 0
 Stopped: 0
Images: 0
Server Version: 1.11.1
Storage Driver: devicemapper
 Pool Name: docker-253:1-67168386-pool
 Pool Blocksize: 65.54 kB
 Base Device Size: 10.74 GB
 Backing Filesystem: xfs
 Data file: /dev/loop0
 Metadata file: /dev/loop1
 Data Space Used: 11.8 MB
 Data Space Total: 107.4 GB
 Data Space Available: 26.65 GB
 Metadata Space Used: 581.6 kB
 Metadata Space Total: 2.147 GB
 Metadata Space Available: 2.147 GB
 Udev Sync Supported: true
 Deferred Removal Enabled: false
 Deferred Deletion Enabled: false
 Deferred Deleted Device Count: 0
 Data loop file: /var/lib/docker/devicemapper/devicemapper/data
 WARNING: Usage of loopback devices is strongly discouraged for production use. Either use `--storage-opt dm.thinpooldev` or use `--storage-opt dm.no_warn_on_loop_devices=true` to suppress this warning.
 Metadata loop file: /var/lib/docker/devicemapper/devicemapper/metadata
 Library Version: 1.02.107-RHEL7 (2015-12-01)
Logging Driver: json-file
Cgroup Driver: cgroupfs
 Volume: local
 Network: host bridge null
Kernel Version: 3.10.0-327.10.1.el7.x86_64
Operating System: Red Hat Enterprise Linux Server 7.2 (Maipo)
OSType: linux
Architecture: x86_64
CPUs: 2
Total Memory: 7.64 GiB
Name: systst-xxx
Docker Root Dir: /var/lib/docker
Debug mode (client): false
Debug mode (server): false
Http Proxy: http ://
Https Proxy: https ://
WARNING: bridge-nf-call-iptables is disabled
WARNING: bridge-nf-call-ip6tables is disabled

# docker run hello-world"
Unable to find image 'hello-world:latest' locally
Pulling repository
docker: Could not reach any registry endpoint.
See 'docker run --help'.

(Noboby) #2


Docker version 1.11.2, build b9f10c9

(Jancoop) #3

I was getting the sam:
Error response from daemon: login attempt to failed with status: 401 Unauthorized

Problem was Proxy environment

I asked Proxy admin to excempt from SSL interception the following:

https for site * (I identifiet these 2 in network trace, but possibly there are others:,

After implementing this change 'docker login succeeds