requests.exceptions.ConnectionError:HTTPSConnectionPool(host ='',port = 2376):URL:/v1.24/version超过了最大重试次数-Windows上的Docker

时间:2018-09-09 14:04:56

标签: java docker docker-compose

我已经通过了链接Ubuntu 16.04 - > ERROR: Couldn't connect to Docker daemon - you might need to run `docker-machine start default`,但是它还没有解决我的问题。

我已经在Windows-10机器上设置了Docker,并且只是尝试运行代码:: https://github.com/sqshq/PiggyMetrics

pc@DESKTOP-NQ639DU MINGW64 ~/Desktop/PiggyMetrix/PiggyMetrics (master)
$ docker --version
Docker version 18.03.0-ce, build 0520e24302

pc@DESKTOP-NQ639DU MINGW64 ~/Desktop/PiggyMetrix/PiggyMetrics (master)
$ docker-compose --version
docker-compose version 1.20.1, build 5d8c71b2

现在,我正在从docker-compose -f docker-compose.yml -f docker-compose.dev.yml up运行代码,并遇到以下错误:

pc@DESKTOP-NQ639DU MINGW64 ~/Desktop/PiggyMetrix/PiggyMetrics (master)
$ docker-compose -f docker-compose.yml -f docker-compose.dev.yml up
ERROR: Couldn't connect to Docker daemon - you might need to run `docker-machine start default`.

我在--verbose模式下运行了代码,这给了我很多错误。有什么建议,如何解决?

pc@DESKTOP-NQ639DU MINGW64 ~/Desktop/PiggyMetrix/PiggyMetrics (master)
$ docker-compose --verbose -f docker-compose.yml -f docker-compose.dev.yml up
compose.config.config.find: Using configuration files: .\docker-compose.yml,.\docker-compose.dev.yml
docker.utils.config.find_config_file: Trying paths: ['C:\\Users\\pc\\.docker\\config.json', 'C:\\Users\\pc\\.dockercfg']
docker.utils.config.find_config_file: No config file found
docker.utils.config.find_config_file: Trying paths: ['C:\\Users\\pc\\.docker\\config.json', 'C:\\Users\\pc\\.dockercfg']
docker.utils.config.find_config_file: No config file found
urllib3.connectionpool._new_conn: Starting new HTTPS connection (1): 192.168.99.100
Traceback (most recent call last):
  File "site-packages\urllib3\connection.py", line 141, in _new_conn
  File "site-packages\urllib3\util\connection.py", line 83, in create_connection
  File "site-packages\urllib3\util\connection.py", line 73, in create_connection
TimeoutError: [WinError 10060] A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "site-packages\urllib3\connectionpool.py", line 600, in urlopen
  File "site-packages\urllib3\connectionpool.py", line 345, in _make_request
  File "site-packages\urllib3\connectionpool.py", line 844, in _validate_conn
  File "site-packages\urllib3\connection.py", line 284, in connect
  File "site-packages\urllib3\connection.py", line 150, in _new_conn
urllib3.exceptions.NewConnectionError: <urllib3.connection.VerifiedHTTPSConnection object at 0x000001E471029978>: Failed to establish a new connection: [WinError 10060] A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "site-packages\requests\adapters.py", line 440, in send
  File "site-packages\urllib3\connectionpool.py", line 649, in urlopen
  File "site-packages\urllib3\util\retry.py", line 388, in increment
urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='192.168.99.100', port=2376): Max retries exceeded with url: /v1.24/version (Caused by NewConnectionError('<urllib3.connection.VerifiedHTTPSConnection object at 0x000001E471029978>: Failed to establish a new connection: [WinError 10060] A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond',))

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "docker-compose", line 6, in <module>
  File "compose\cli\main.py", line 71, in main
  File "compose\cli\main.py", line 124, in perform_command
  File "compose\cli\command.py", line 41, in project_from_options
  File "compose\cli\command.py", line 121, in get_project
  File "compose\cli\command.py", line 95, in get_client
  File "site-packages\docker\api\daemon.py", line 172, in version
  File "site-packages\docker\utils\decorators.py", line 46, in inner
  File "site-packages\docker\api\client.py", line 194, in _get
  File "site-packages\requests\sessions.py", line 521, in get
  File "site-packages\requests\sessions.py", line 508, in request
  File "site-packages\requests\sessions.py", line 618, in send
  File "site-packages\requests\adapters.py", line 508, in send
requests.exceptions.ConnectionError: HTTPSConnectionPool(host='192.168.99.100', port=2376): Max retries exceeded with url: /v1.24/version (Caused by NewConnectionError('<urllib3.connection.VerifiedHTTPSConnection object at 0x000001E471029978>: Failed to establish a new connection: [WinError 10060] A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond',))
[6968] Failed to execute script docker-compose

另一个 ::

pc@DESKTOP-NQ639DU MINGW64 ~/Desktop/PiggyMetrix/PiggyMetrics (master)
$ docker images
error during connect: Get https://192.168.99.100:2376/v1.37/images/json: dial tcp 192.168.99.100:2376: connectex: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond.

现在,我遇到以下错误:

Error setting up host only network on machine start: C:\Program Files\Oracle\VirtualBox\VBoxManage.exe modifyvm default --nic2 hostonly --nictype2 82540EM --nicpromisc2 deny --hostonlyadapter2 VirtualBox Host-Only Ethernet Adapter #2 --cableconnected2 on failed:
VBoxManage.exe: error: Code E_FAIL (0x80004005) - Unspecified error (extended info not available)
VBoxManage.exe: error: Context: "LockMachine(a->session, LockType_Write)" at line 525 of file VBoxManageModifyVM.cpp
Looks like something went wrong in step ´Checking status on default´... Press any key to continue...

0 个答案:

没有答案