我使用的是 Windows 7、VirtualBox 5.0.4、Docker 工具箱 1.9.0。当我运行快速入门时,我得到:
Creating Machine default...
Running pre-create checks...
Creating machine...
Error creating machine: Error in driver during machine creation: Maximum number of retries (5) exceeded
Looks like something went wrong... Press any key to continue...
Run Code Online (Sandbox Code Playgroud)
但是当我打开 VirtualBox 并查看时,我确实得到了一个正在运行的“默认”VM。在我的 VBox.log 中,我看到(完整文件在这里):
00:00:00.696246 HM: HMR3Init: VT-x w/ nested paging and unrestricted guest execution hw support
Run Code Online (Sandbox Code Playgroud)
所以也许 VT-X 支持对我来说没问题。在日志文件的末尾,我看到 D-Bus 没有安装的不祥之兆:
00:00:46.950561 VMMDev: Guest Log: 00:00:10.018836 vminfo Error: Unable to connect to system D-Bus (3/3): D-Bus not installed
Run Code Online (Sandbox Code Playgroud)
D-Bus 问题已在此处报告https://github.com/docker/toolbox/issues/214在此之后直接再次运行快速入门时,我收到有关获取 IP 地址的错误消息:
Machine default already exists in VirtualBox.
Setting environment variables for machine default...
Error running connection boilerplate: Error getting driver URL: Something went wrong running an SSH command!
command : ip addr show dev eth1
err : exit status 255
output :
## .
## ## ## ==
## ## ## ## ## ===
/"""""""""""""""""\___/ ===
~~~ {~~ ~~~~ ~~~ ~~~~ ~~~ ~ / ===- ~~~
\______ o __/
\ \ __/
\____\_______/
Error getting IP address: Something went wrong running an SSH command!
command : ip addr show dev eth1
err : exit status 255
output :
docker is configured to use the default machine with IP
For help getting started, check out the docs at https://docs.docker.com
NOTE: When using interactive commands, prepend winpty. Examples: 'winpty docker run -it ...', 'winpty docker exec -it ...'.
Run Code Online (Sandbox Code Playgroud)
如果我运行一个命令,我会收到另一条与连接相关的消息:
$ winpty docker run hello-world
An error occurred trying to connect: Post http://localhost:2375/v1.21/containers
/create: dial tcp 127.0.0.1:2375: ConnectEx tcp: No connection could be made because the target machine actively refused it.
Run Code Online (Sandbox Code Playgroud)
此时我去https://www.virtualbox.org/wiki/Testbuilds得到VirtualBox 5.0.9,然后卸载Docker Toolboox,删除默认VM和.docker目录,重新安装Toolbox,重新运行它,遇到同样的问题:
Creating Machine default...
Creating CA: C:\Users\marwick\.docker\machine\certs\ca.pem
Creating client certificate: C:\Users\marwick\.docker\machine\certs\cert.pem
Running pre-create checks...
Creating machine...
Error creating machine: Error in driver during machine creation: Maximum number of retries (5) exceeded
Looks like something went wrong... Press any key to continue...
Run Code Online (Sandbox Code Playgroud)
这次尝试的日志文件在这里:http : //pastebin.com/9VjD9t6P
我怎样才能让它工作?
小智 12
有同样的问题(运行 docker 命令给出错误消息:无法建立连接,因为目标机器主动拒绝了它)。
权限存在问题(可能目标计算机是在不同的用户帐户下创建的)。
这对我有用:打开 Oracle VM VirtualBox 并右键单击名为“default”的机器。如果它正在运行,请选择“关闭 -> 关闭电源”。然后选择“删除...”并点击“删除所有文件”按钮。
关闭 Oracle VM VirtualBox 并再次运行 Docker_Quickstart。它将创建一个没有权限问题的新默认 VM。
| 归档时间: |
|
| 查看次数: |
14017 次 |
| 最近记录: |