title: Ubuntu, Docker - proxyconnect tcp: tls: oversized record received with length 20527
body: <p>I am running a docker binary I built (following <a href="http://oyvindsk.com/writing/docker-build-from-source" rel="noreferrer">this</a>) and when I do a <code>docker pull</code>, I get this error.</p>
  
  <blockquote>
    <p>Error response from daemon: Get <a href="https://registry-1.docker.io/v2/" rel="noreferrer">https://registry-1.docker.io/v2/</a>: proxyconnect tcp: tls: oversized record received with length 20527</p>
  </blockquote>
  
  <p>I have set the proxy as mentioned <a href="https://docs.docker.com/config/daemon/systemd/" rel="noreferrer">here</a>, and the <code>pull</code> works fine with the default daemon and the same proxy settings. Changing DNS to 8.8.8.8 doesn't seem to help. </p>
  
  <pre><code>ping registry-1.docker.io
  </code></pre>
  
  <p>results in 100% packet loss.</p>
  
  <p><code>docker info</code> gives this </p>
  
  <pre><code>Containers: 0
   Running: 0
   Paused: 0
   Stopped: 0
  Images: 0
  Server Version: dev
  Storage Driver: vfs
  Logging Driver: json-file
  Cgroup Driver: cgroupfs
  Plugins:
   Volume: local
   Network: bridge host macvlan null overlay
   Log: awslogs fluentd gcplogs gelf journald json-file logentries splunk syslog
  Swarm: inactive
  Runtimes: runc
  Default Runtime: runc
  Init Binary: docker-init
  containerd version: 773c489c9c1b21a6d78b5c538cd395416ec50f88
  runc version: 4fc53a81fb7c994640722ac585fa9ca548971871
  init version: 949e6fa (expected: fec3683)
  Security Options:
   apparmor
   seccomp
    Profile: default
  Kernel Version: 4.13.0-43-generic
  Operating System: Ubuntu 16.04.4 LTS
  OSType: linux
  Architecture: x86_64
  CPUs: 4
  Total Memory: 3.853GiB
  Name: bhavana-docker
  ID: UKZT:U4LR:PBOV:GLXP:XXUP:MZ74:WXWL:3RT7:MOG5:YGMC:HAFI:7PYM
  Docker Root Dir: /var/lib/docker
  Debug Mode (client): false
  Debug Mode (server): false
  HTTP Proxy: &lt;suppressed&gt;
  HTTPS Proxy: &lt;suppressed&gt;
  Registry: https://index.docker.io/v1/
  Labels:
  Experimental: false
  Insecure Registries:
   registry-1.docker.io
   127.0.0.0/8
  Live Restore Enabled: false
  </code></pre>
  
  <p>What is the fix for this error?</p>