Docker Limit Concurrent Uploads and Downloads: For Unreliable Network Connections

By default, Docker opens up multiple upload or download connections, so that it can move multiple layers of images at a given time. This is a performance boost, when used with a reliable connection. But if your network connectivity is not so reliable, doing one thing at a time and waiting for it to succeed can make sure the number of failed attempts are low, and the process completes comparatively faster.

How

  1. Open /etc/docker/daemon.json (If the daemon.json file doesn’t exist in /etc/docker/, create it.).
  2. Add following values:
    {
    	"max-concurrent-uploads": 1,
    	"max-concurrent-downloads": 1
    }
  3. Restart Docker Daemon: sudo service docker restart.

Leave a Reply