Machine: No IP on Docker-Machine Quickstart

Created on 10 Nov 2015  ·  62Comments  ·  Source: docker/machine

I ran the quickstart and had the following output:


dcook:~/ $ bash --login '/Applications/Docker/Docker Quickstart Terminal.app/Contents/Resources/Scripts/start.sh' --debug                                       [9:03:08]
Machine default already exists in VirtualBox.
Setting environment variables for machine default...


                        ##         .
                  ## ## ##        ==
               ## ## ## ## ##    ===
           /"""""""""""""""""\___/ ===
      ~~~ {~~ ~~~~ ~~~ ~~~~ ~~~ ~ /  ===- ~~~
           \______ o           __/
             \    \         __/
              \____\_______/


Password:
Password:
Password:
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

Password:

drivevirtualbox kinbug

Most helpful comment

The suggestion by nathanleclaire ( Dec 10, 2015 ) also worked for me.
Run

docker-machine rm -f default 
docker-machine --debug create -d virtualbox default

All 62 comments

Versions:


dcook:~/ $ docker-machine -v                                                                                                                                    [9:16:29]
docker-machine version 0.5.0 (04cfa58)
dcook:~/ $ docker -v                                                                                                                                            [9:16:38]
Docker version 1.9.0, build 76d6bc9
dcook:~/ $ sw_vers                                                                                                                                              [9:16:44]
ProductName:    Mac OS X
ProductVersion: 10.11.1
BuildVersion:   15B42

cc @nathanleclaire

@dcunited08 Does docker-machine rm default and re-trying opening the Quickstart fix it?

Also, please post the output of VBoxManage list hostonlyifs command if you get a chance.

Cleanup and VBoxManage settings:


dcook:~/ $ docker-machine rm default                                                                                                                                     [9:39:11]
Error removing host "default": Loading host from store failed: Host does not exist: "default"
dcook:~/ $ VBoxManage list hostonlyifs                                                                                                                                   [9:39:12]
Name:            vboxnet0
GUID:            786f6276-656e-4074-8000-0a0027000000
DHCP:            Disabled
IPAddress:       192.168.33.1
NetworkMask:     255.255.255.0
IPV6Address:
IPV6NetworkMaskPrefixLength: 0
HardwareAddress: 0a:00:27:00:00:00
MediumType:      Ethernet
Status:          Down
VBoxNetworkName: HostInterfaceNetworking-vboxnet0

Name:            vboxnet1
GUID:            786f6276-656e-4174-8000-0a0027000001
DHCP:            Disabled
IPAddress:       192.168.99.1
NetworkMask:     255.255.255.0
IPV6Address:
IPV6NetworkMaskPrefixLength: 0
HardwareAddress: 0a:00:27:00:00:01
MediumType:      Ethernet
Status:          Down
VBoxNetworkName: HostInterfaceNetworking-vboxnet1

Name:            vboxnet2
GUID:            786f6276-656e-4274-8000-0a0027000002
DHCP:            Disabled
IPAddress:       192.168.59.3
NetworkMask:     255.255.255.0
IPV6Address:
IPV6NetworkMaskPrefixLength: 0
HardwareAddress: 0a:00:27:00:00:02
MediumType:      Ethernet
Status:          Down
VBoxNetworkName: HostInterfaceNetworking-vboxnet2

dcook:~/ $

Rerunning Quickstart Script:


Last login: Wed Nov 11 09:39:11 on ttys003
bash --login '/Applications/Docker/Docker Quickstart Terminal.app/Contents/Resources/Scripts/start.sh'
dcook:~/ $ bash --login '/Applications/Docker/Docker Quickstart Terminal.app/Contents/Resources/Scripts/start.sh'                                                        [9:40:20]
Creating Machine default...
Running pre-create checks...
Creating machine...
Error creating machine: Error in driver during machine creation: Maximum number of retries (5) exceeded
Setting environment variables for machine default...


                        ##         .
                  ## ## ##        ==
               ## ## ## ## ##    ===
           /"""""""""""""""""\___/ ===
      ~~~ {~~ ~~~~ ~~~ ~~~~ ~~~ ~ /  ===- ~~~
           \______ o           __/
             \    \         __/
              \____\_______/


Password:
Password:
Password:
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

Password:
Password:
Password:
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  :

dcook:~/ $

same here on a Mac OS X

+1
MacOS 10.10.4 (14E46)

docker --version Docker version 1.9.0, build 76d6bc9

docker-machine --version docker-machine version 0.5.0 (04cfa58)

virtual box 5.0.8 r103449

                        ##         .
                  ## ## ##        ==
               ## ## ## ## ##    ===
           /"""""""""""""""""\___/ ===
      ~~~ {~~ ~~~~ ~~~ ~~~~ ~~~ ~ /  ===- ~~~
           \______ 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

docker ps Cannot connect to the Docker daemon. Is the docker daemon running on this host?

docker-machine env default doesn't work also

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  : 

can you try docker-machine -D ls and or docker-machine -D env default

docker-machine start default
Too many retries waiting for SSH to be available. Last error: Maximum number of retries (60) exceeded
docker quick start terminal prints Error running connection boilerplate
docker-machine ls

error getting URL for host default: Something went wrong running an SSH command!
command : ip addr show dev eth1
err     : exit status 255
output  : 

NAME      ACTIVE   DRIVER       STATE     URL   SWARM
default   *        virtualbox   Running         

docker-machine -D env default or docker-machine -D env default

Docker Machine Version: 0.5.0 (04cfa58)
Found binary path at /usr/local/bin/docker-machine-driver-virtualbox
Launching plugin server for driver virtualbox
Plugin server listening at address 127.0.0.1:60724
() Calling RpcServerDriver.GetVersion
Using API Version 1
() Calling RpcServerDriver.SetConfigRaw
() Calling RpcServerDriver.GetMachineName
(default) Calling RpcServerDriver.GetState
(default) DBG | COMMAND: /usr/local/bin/VBoxManage showvminfo default --machinereadable
(default) DBG | STDOUT:
(default) DBG | {
(default) DBG | name="default"
(default) DBG | groups="/"
(default) DBG | ostype="Linux 2.6 / 3.x / 4.x (64-bit)"
(default) DBG | UUID="dc72fbb6-d780-4931-8452-0bef089967e4"
(default) DBG | CfgFile="/Users/ssheypak/.docker/machine/machines/default/default/default.vbox"
(default) DBG | SnapFldr="/Users/ssheypak/.docker/machine/machines/default/default/Snapshots"
(default) DBG | LogFldr="/Users/ssheypak/.docker/machine/machines/default/default/Logs"
(default) DBG | hardwareuuid="dc72fbb6-d780-4931-8452-0bef089967e4"
(default) DBG | memory=2048
(default) DBG | pagefusion="off"
(default) DBG | vram=8
(default) DBG | cpuexecutioncap=100
(default) DBG | hpet="on"
(default) DBG | chipset="piix3"
(default) DBG | firmware="BIOS"
(default) DBG | cpus=1
(default) DBG | pae="on"
(default) DBG | longmode="on"
(default) DBG | cpuid-portability-level=0
(default) DBG | bootmenu="disabled"
(default) DBG | boot1="dvd"
(default) Calling RpcServerDriver.GetURL
(default) DBG | boot2="dvd"
(default) DBG | boot3="disk"
(default) DBG | boot4="none"
(default) DBG | acpi="on"
(default) DBG | ioapic="on"
(default) DBG | biossystemtimeoffset=0
(default) DBG | rtcuseutc="on"
(default) DBG | hwvirtex="on"
(default) DBG | nestedpaging="on"
(default) DBG | largepages="on"
(default) DBG | vtxvpid="on"
(default) DBG | vtxux="on"
(default) DBG | paravirtprovider="default"
(default) DBG | VMState="running"
(default) DBG | VMStateChangeTime="2015-11-18T15:52:31.584000000"
(default) DBG | monitorcount=1
(default) DBG | accelerate3d="off"
(default) DBG | accelerate2dvideo="off"
(default) DBG | teleporterenabled="off"
(default) DBG | teleporterport=0
(default) DBG | teleporteraddress=""
(default) DBG | teleporterpassword=""
(default) DBG | tracing-enabled="off"
(default) DBG | tracing-allow-vm-access="off"
(default) DBG | tracing-config=""
(default) DBG | autostart-enabled="off"
(default) DBG | autostart-delay=0
(default) DBG | defaultfrontend=""
(default) DBG | storagecontrollername0="SATA"
(default) DBG | storagecontrollertype0="IntelAhci"
(default) DBG | storagecontrollerinstance0="0"
(default) DBG | storagecontrollermaxportcount0="30"
(default) DBG | storagecontrollerportcount0="30"
(default) DBG | storagecontrollerbootable0="on"
(default) DBG | "SATA-0-0"="/Users/ssheypak/.docker/machine/machines/default/boot2docker.iso"
(default) DBG | "SATA-ImageUUID-0-0"="8396b34b-15ee-4a54-933a-4f73e945ffc3"
(default) DBG | "SATA-tempeject"="off"
(default) DBG | "SATA-IsEjected"="off"
(default) DBG | "SATA-1-0"="/Users/ssheypak/.docker/machine/machines/default/disk.vmdk"
(default) DBG | "SATA-ImageUUID-1-0"="f01f176e-c1c3-4d39-9378-1a43691ad03d"
(default) DBG | "SATA-2-0"="none"
(default) DBG | "SATA-3-0"="none"
(default) DBG | "SATA-4-0"="none"
(default) DBG | "SATA-5-0"="none"
(default) DBG | "SATA-6-0"="none"
(default) DBG | "SATA-7-0"="none"
(default) DBG | "SATA-8-0"="none"
(default) DBG | "SATA-9-0"="none"
(default) DBG | "SATA-10-0"="none"
(default) DBG | "SATA-11-0"="none"
(default) DBG | "SATA-12-0"="none"
(default) DBG | "SATA-13-0"="none"
(default) DBG | "SATA-14-0"="none"
(default) DBG | "SATA-15-0"="none"
(default) DBG | "SATA-16-0"="none"
(default) DBG | "SATA-17-0"="none"
(default) DBG | "SATA-18-0"="none"
(default) DBG | "SATA-19-0"="none"
(default) DBG | "SATA-20-0"="none"
(default) DBG | "SATA-21-0"="none"
(default) DBG | "SATA-22-0"="none"
(default) DBG | "SATA-23-0"="none"
(default) DBG | "SATA-24-0"="none"
(default) DBG | "SATA-25-0"="none"
(default) DBG | "SATA-26-0"="none"
(default) DBG | "SATA-27-0"="none"
(default) DBG | "SATA-28-0"="none"
(default) DBG | "SATA-29-0"="none"
(default) DBG | natnet1="nat"
(default) DBG | macaddress1="08002722CCAE"
(default) DBG | cableconnected1="on"
(default) DBG | nic1="nat"
(default) DBG | nictype1="82540EM"
(default) DBG | nicspeed1="0"
(default) DBG | mtu="0"
(default) DBG | sockSnd="64"
(default) DBG | sockRcv="64"
(default) DBG | tcpWndSnd="64"
(default) DBG | tcpWndRcv="64"
(default) DBG | Forwarding(0)="ssh,tcp,127.0.0.1,56258,,22"
(default) DBG | hostonlyadapter2="vboxnet0"
(default) DBG | macaddress2="08002732B3FD"
(default) DBG | cableconnected2="on"
(default) DBG | nic2="hostonly"
(default) DBG | nictype2="82540EM"
(default) DBG | nicspeed2="0"
(default) DBG | nic3="none"
(default) DBG | nic4="none"
(default) DBG | nic5="none"
(default) DBG | nic6="none"
(default) DBG | nic7="none"
(default) DBG | nic8="none"
(default) DBG | hidpointing="ps2mouse"
(default) DBG | hidkeyboard="ps2kbd"
(default) DBG | uart1="off"
(default) DBG | uart2="off"
(default) DBG | lpt1="off"
(default) DBG | lpt2="off"
(default) DBG | audio="none"
(default) DBG | clipboard="disabled"
(default) DBG | draganddrop="disabled"
(default) DBG | SessionName="headless"
(default) DBG | VideoMode="720,400,0"@0,0 1
(default) DBG | vrde="off"
(default) DBG | usb="off"
(default) DBG | ehci="off"
(default) DBG | xhci="off"
(default) DBG | SharedFolderNameMachineMapping1="Users"
(default) DBG | SharedFolderPathMachineMapping1="/Users"
(default) DBG | VRDEActiveConnection="off"
(default) DBG | VRDEClients=0
(default) DBG | vcpenabled="off"
(default) DBG | vcpscreens=0
(default) DBG | vcpfile="/Users/ssheypak/.docker/machine/machines/default/default/default.webm"
(default) DBG | vcpwidth=1024
(default) DBG | vcpheight=768
(default) DBG | vcprate=512
(default) DBG | vcpfps=25
(default) DBG | GuestMemoryBalloon=0
(default) DBG | GuestOSType="Linux26_64"
(default) DBG | GuestAdditionsRunLevel=2
(default) DBG | GuestAdditionsVersion="5.0.8 r103449"
(default) DBG | GuestAdditionsFacility_VirtualBox Base Driver=50,1447861967551
(default) DBG | GuestAdditionsFacility_VirtualBox System Service=50,1447861983707
(default) DBG | GuestAdditionsFacility_Seamless Mode=0,1447861967550
(default) DBG | GuestAdditionsFacility_Graphics Mode=0,1447861967550
(default) DBG | }
(default) DBG | STDERR:
(default) DBG | {
(default) DBG | }
(default) DBG | COMMAND: /usr/local/bin/VBoxManage showvminfo default --machinereadable
(default) DBG | STDOUT:
(default) DBG | {
(default) DBG | name="default"
(default) DBG | groups="/"
(default) DBG | ostype="Linux 2.6 / 3.x / 4.x (64-bit)"
(default) DBG | UUID="dc72fbb6-d780-4931-8452-0bef089967e4"
(default) DBG | CfgFile="/Users/ssheypak/.docker/machine/machines/default/default/default.vbox"
(default) DBG | SnapFldr="/Users/ssheypak/.docker/machine/machines/default/default/Snapshots"
(default) DBG | LogFldr="/Users/ssheypak/.docker/machine/machines/default/default/Logs"
(default) DBG | hardwareuuid="dc72fbb6-d780-4931-8452-0bef089967e4"
(default) DBG | memory=2048
(default) DBG | pagefusion="off"
(default) DBG | vram=8
(default) DBG | cpuexecutioncap=100
(default) DBG | hpet="on"
(default) DBG | chipset="piix3"
(default) DBG | firmware="BIOS"
(default) DBG | cpus=1
(default) DBG | pae="on"
(default) DBG | longmode="on"
(default) DBG | cpuid-portability-level=0
(default) DBG | bootmenu="disabled"
(default) DBG | boot1="dvd"
(default) DBG | boot2="dvd"
(default) DBG | boot3="disk"
(default) DBG | boot4="none"
(default) DBG | acpi="on"
(default) DBG | ioapic="on"
(default) DBG | biossystemtimeoffset=0
(default) DBG | rtcuseutc="on"
(default) DBG | hwvirtex="on"
(default) DBG | nestedpaging="on"
(default) DBG | largepages="on"
(default) DBG | vtxvpid="on"
(default) DBG | vtxux="on"
(default) DBG | paravirtprovider="default"
(default) DBG | VMState="running"
(default) DBG | VMStateChangeTime="2015-11-18T15:52:31.584000000"
(default) DBG | monitorcount=1
(default) DBG | accelerate3d="off"
(default) DBG | accelerate2dvideo="off"
(default) DBG | teleporterenabled="off"
(default) DBG | teleporterport=0
(default) DBG | teleporteraddress=""
(default) DBG | teleporterpassword=""
(default) DBG | tracing-enabled="off"
(default) DBG | tracing-allow-vm-access="off"
(default) DBG | tracing-config=""
(default) DBG | autostart-enabled="off"
(default) DBG | autostart-delay=0
(default) DBG | defaultfrontend=""
(default) DBG | storagecontrollername0="SATA"
(default) DBG | storagecontrollertype0="IntelAhci"
(default) DBG | storagecontrollerinstance0="0"
(default) DBG | storagecontrollermaxportcount0="30"
(default) DBG | storagecontrollerportcount0="30"
(default) DBG | storagecontrollerbootable0="on"
(default) DBG | "SATA-0-0"="/Users/ssheypak/.docker/machine/machines/default/boot2docker.iso"
(default) DBG | "SATA-ImageUUID-0-0"="8396b34b-15ee-4a54-933a-4f73e945ffc3"
(default) DBG | "SATA-tempeject"="off"
(default) DBG | "SATA-IsEjected"="off"
(default) DBG | "SATA-1-0"="/Users/ssheypak/.docker/machine/machines/default/disk.vmdk"
(default) DBG | "SATA-ImageUUID-1-0"="f01f176e-c1c3-4d39-9378-1a43691ad03d"
(default) DBG | "SATA-2-0"="none"
(default) DBG | "SATA-3-0"="none"
(default) DBG | "SATA-4-0"="none"
(default) DBG | "SATA-5-0"="none"
(default) DBG | "SATA-6-0"="none"
(default) DBG | "SATA-7-0"="none"
(default) DBG | "SATA-8-0"="none"
(default) DBG | "SATA-9-0"="none"
(default) DBG | "SATA-10-0"="none"
(default) DBG | "SATA-11-0"="none"
(default) DBG | "SATA-12-0"="none"
(default) DBG | "SATA-13-0"="none"
(default) DBG | "SATA-14-0"="none"
(default) DBG | "SATA-15-0"="none"
(default) DBG | "SATA-16-0"="none"
(default) DBG | "SATA-17-0"="none"
(default) DBG | "SATA-18-0"="none"
(default) DBG | "SATA-19-0"="none"
(default) DBG | "SATA-20-0"="none"
(default) DBG | "SATA-21-0"="none"
(default) DBG | "SATA-22-0"="none"
(default) DBG | "SATA-23-0"="none"
(default) DBG | "SATA-24-0"="none"
(default) DBG | "SATA-25-0"="none"
(default) DBG | "SATA-26-0"="none"
(default) DBG | "SATA-27-0"="none"
(default) DBG | "SATA-28-0"="none"
(default) DBG | "SATA-29-0"="none"
(default) DBG | natnet1="nat"
(default) DBG | macaddress1="08002722CCAE"
(default) DBG | cableconnected1="on"
(default) DBG | nic1="nat"
(default) DBG | nictype1="82540EM"
(default) DBG | nicspeed1="0"
(default) DBG | mtu="0"
(default) DBG | sockSnd="64"
(default) DBG | sockRcv="64"
(default) DBG | tcpWndSnd="64"
(default) DBG | tcpWndRcv="64"
(default) DBG | Forwarding(0)="ssh,tcp,127.0.0.1,56258,,22"
(default) DBG | hostonlyadapter2="vboxnet0"
(default) DBG | macaddress2="08002732B3FD"
(default) DBG | cableconnected2="on"
(default) DBG | nic2="hostonly"
(default) DBG | nictype2="82540EM"
(default) DBG | nicspeed2="0"
(default) DBG | nic3="none"
(default) DBG | nic4="none"
(default) DBG | nic5="none"
(default) DBG | nic6="none"
(default) DBG | nic7="none"
(default) DBG | nic8="none"
(default) DBG | hidpointing="ps2mouse"
(default) DBG | hidkeyboard="ps2kbd"
(default) DBG | uart1="off"
(default) DBG | uart2="off"
(default) DBG | lpt1="off"
(default) DBG | lpt2="off"
(default) DBG | audio="none"
(default) DBG | clipboard="disabled"
(default) DBG | draganddrop="disabled"
(default) DBG | SessionName="headless"
(default) DBG | VideoMode="720,400,0"@0,0 1
(default) DBG | vrde="off"
(default) DBG | usb="off"
(default) DBG | ehci="off"
(default) DBG | xhci="off"
(default) DBG | SharedFolderNameMachineMapping1="Users"
(default) DBG | SharedFolderPathMachineMapping1="/Users"
(default) DBG | VRDEActiveConnection="off"
(default) DBG | VRDEClients=0
(default) DBG | vcpenabled="off"
(default) DBG | vcpscreens=0
(default) DBG | vcpfile="/Users/ssheypak/.docker/machine/machines/default/default/default.webm"
(default) DBG | vcpwidth=1024
(default) DBG | vcpheight=768
(default) DBG | vcprate=512
(default) DBG | vcpfps=25
(default) DBG | GuestMemoryBalloon=0
(default) DBG | GuestOSType="Linux26_64"
(default) DBG | GuestAdditionsRunLevel=2
(default) DBG | GuestAdditionsVersion="5.0.8 r103449"
(default) DBG | GuestAdditionsFacility_VirtualBox Base Driver=50,1447861967551
(default) DBG | GuestAdditionsFacility_VirtualBox System Service=50,1447861983707
(default) DBG | GuestAdditionsFacility_Seamless Mode=0,1447861967550
(default) DBG | GuestAdditionsFacility_Graphics Mode=0,1447861967550
(default) DBG | }
(default) DBG | STDERR:
(default) DBG | {
(default) DBG | }
(default) DBG | Using SSH client type: external
(default) DBG | About to run SSH command:
(default) DBG | ip addr show dev eth1
(default) DBG | SSH cmd err, output: exit status 255: 
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  : 

Having the same issue here... Do you have any news or workaround related to this problem?

@felipesabino this one helped me: https://github.com/docker/toolbox/issues/273#issuecomment-157805699

I am having the same issue as well. Virtually the same setup as @seregasheypak. #273 did not help me.

I noticed that this happened after I restarted my computer. My VM's in VirtualBox were not shut down properly. Might have something to do with it.

Exit status 255 ubiquitously implies that something went wrong with the ssh command itself. Please post the output of docker-machine --debug ssh default -vvv here (even on the broken/errored instance if it's possible) if you encounter such an issue. It will contain useful information for our debugging. Thanks.

I've managed to reproduce the issue with the following steps:

  1. Create vm 1
  2. Run a docker container on it (I am running gliderlabs/consul-server)
  3. Create vm 2 as a swarm master
  4. Run a docker container on it (I am running gliderlabs/consul-agent)
  5. Restart computer
  6. Open QuickStart terminal and wait for "default" vm to start up
  7. Run docker-machine start vm-1
  8. Run docker-machine start vm-2

In my scenario, step 8 froze and eventually timed out trying to SSH into the box. Here's the result of the last command:

$ docker-machine start vm-2
(vm-2) OUT | Starting VM...
Too many retries waiting for SSH to be available.  Last error: Maximum number of retries (60) exceeded

I then tried to list my machines and got another ssh error:

$ docker-machine ls
error getting URL for host vm-2: Something went wrong running an SSH command!
command : ip addr show dev eth1
err     : exit status 255
output  : 

NAME                  ACTIVE   DRIVER       STATE     URL                       SWARM
default               *        virtualbox   Running   tcp://192.168.99.2:2376   
vm-2                  -        virtualbox   Running                             vm-2 (master)
vm-1                  -        virtualbox   Running   tcp://192.168.99.3:2376

I followed @nathanleclaire's request to run docker-machine --debug ssh default -vvv. I am able to successfully ssh into both default and vm-1 in my scenario above. Attempting to ssh into vm-2 fails. Rather than posting the entire output, I found the point where docker-machine ssh default diverges from docker-machine ssh vm-2. These are the results from the point of divergence:

Output of successful ssh:

...
debug1: Offering RSA public key: /Users/kcraft/.docker/machine/machines/default/id_rsa
debug3: send_pubkey_test
debug2: we sent a publickey packet, wait for reply
debug1: Server accepts key: pkalg ssh-rsa blen 279
debug2: input_userauth_pk_ok: fp a2:85:c3:39:49:fe:f1:51:98:4e:11:a9:cb:22:d6:a8
debug3: sign_and_send_pubkey: RSA a2:85:c3:39:49:fe:f1:51:98:4e:11:a9:cb:22:d6:a8
debug1: read PEM private key done: type RSA
debug1: Authentication succeeded (publickey).
Authenticated to 127.0.0.1 ([127.0.0.1]:49720).
debug1: channel 0: new [client-session]
debug3: ssh_session2_open: channel_new: 0
debug2: channel 0: send open
debug1: Requesting [email protected]
debug1: Entering interactive session.
debug2: callback start
debug2: fd 3 setting TCP_NODELAY
debug3: packet_set_tos: set IP_TOS 0x10
debug2: client_session2_setup: id 0
debug2: channel 0: request pty-req confirm 1
debug1: Sending environment.
...

Output of failed ssh:

...
debug1: Offering RSA public key: /Users/kcraft/.docker/machine/machines/vm-2/id_rsa
debug3: send_pubkey_test
debug2: we sent a publickey packet, wait for reply
debug1: Authentications that can continue: publickey,password,keyboard-interactive
debug2: we did not send a packet, disable method
debug3: authmethod_lookup keyboard-interactive
debug3: remaining preferred: 
debug3: authmethod_is_enabled keyboard-interactive
debug1: Next authentication method: keyboard-interactive
debug2: userauth_kbdint
debug2: we sent a keyboard-interactive packet, wait for reply
debug1: Authentications that can continue: publickey,password,keyboard-interactive
debug3: userauth_kbdint: disable: no info_req_seen
debug2: we did not send a packet, disable method
debug1: No more authentication methods to try.
Permission denied (publickey,password,keyboard-interactive).
exit status 255

After further testing, I have found that if I create a swarm using the "token" method instead of consul, and if I use the Parallels driver to create my VM's, then I no longer have this problem. I'm not sure which of those changes solved the problem.

I've narrowed it down to a problem with VirtualBox. I have the exact same setup as before except I am using the Parallels driver and I am not having any problems. I think it has something to do with the fact that VirtualBox doesn't properly shutdown its VM's when the parent O/S restarts. They just get killed, which corrupts them somehow.

@kcraft @seregasheypak those steps did not work for me either :(

What's your os, virtual box version?

2015-11-25 18:27 GMT+01:00 Felipe Sabino [email protected]:

@kcraft https://github.com/kcraft @seregasheypak
https://github.com/seregasheypak those steps did not work for me either
:(


Reply to this email directly or view it on GitHub
https://github.com/docker/machine/issues/2240#issuecomment-159681233.

Mac OSX Yosemite (10.10.5)
VirtualBox 5.0.10 r104061

@seregasheypak mine are the same as @kcraft

Mac OSX Yosemite (10.10.5)

VirtualBox 5.0.10 r104061

Mine is
OSX 10.11.1

virtual box 5.0.8 r103449

Did you try to restart VBOX, docker, delete vm and recreate new one?

2015-11-26 1:11 GMT+01:00 Felipe Sabino [email protected]:

@seregasheypak https://github.com/seregasheypak mine are the same as
@kcraft https://github.com/kcraft

Mac OSX Yosemite (10.10.5)

VirtualBox 5.0.10 r104061


Reply to this email directly or view it on GitHub
https://github.com/docker/machine/issues/2240#issuecomment-159763352.

Any luck on this? Anyone found a solution?

Anyone still experiencing this, please run docker-machine rm -f default && docker-machine --debug create -d virtualbox default, to see if you still encounter issues. If you still encounter them, please post the output from the aforementioned commands.

I found that nathanleclaire's recommendation above worked, but my original Docker QuickStart Terminal
session still could not run 'hello-world'. Starting a new Terminal session fixed that problem.

Please review my log.

OS X 10.11.2
VBox 5.0.10 r104061
docker-machine version 0.5.2 ( 0456b9f )

docker-machine_create.log.zip

@dcunited08 Do you get this result every time you try a create or is it sporadic?

I had the same issues, eventually I removed the docker-toolbox; virtualbox included and then reinstalled the whole package (DockerToolbox-1.9.1c). Again there were issues.

After running the docker-machine --debug ssh default -vvv command @nathanleclaire mentioned, I found out there was an issue with my ~/.ssh/config file. It did not like a comment that was written there.

After thoroughly cleaning this config file everything worked fine again!

Hope this helps!

@nathanleclaire Everytime I try a local create, I can do it on AWS just fine.

Hi everyone, you might want to try again with latest version of docker-machine (0.5.5) and VirtualBox (5.0.12). Please tell us if it's better

hi, @dgageot

I just tried the version you recommended and got the same problem.I have tested it on windows 7.
docker problem1
docker problem2

@dgageot seeing same issue on mac, using latest versions you mention.

I managed to fix this by running "docker-machine rm -f default && docker-machine --debug create -d virtualbox default"

The suggestion by nathanleclaire ( Dec 10, 2015 ) also worked for me.
Run

docker-machine rm -f default 
docker-machine --debug create -d virtualbox default

Still experiencing the same problem here.

This is my output after $ docker-machine --debug create -d virtualbox default:

$ docker-machine --debug create -d virtualbox default
Docker Machine Version:  0.5.4, build 6643d0e
Found binary path at /usr/local/bin/docker-machine
Launching plugin server for driver virtualbox
Plugin server listening at address 127.0.0.1:61862
() Calling .GetVersion
Using API Version  1

...

(default) DBG | Getting to WaitForSSH function...
(default) DBG | Using SSH client type: external
(default) DBG | About to run SSH command:
(default) DBG | exit 0
(default) DBG | SSH cmd err, output: exit status 255:
(default) DBG | Error getting ssh command 'exit 0' : Something went wrong running an SSH command!
(default) DBG | command : exit 0
(default) DBG | err     : exit status 255
(default) DBG | output  :
(default) DBG |
Opting out of crash reporting.
Error creating machine: Error in driver during machine creation: Too many retries waiting for SSH to be available.  Last error: Maximum number of retries (60) exceeded

I added the full log here https://gist.github.com/felipesabino/5dd56abacfab168ad642

@felipesabino Thanks. It always fails even if you remove machine and try again? It seems to be VirtualBox NAT forwarding failing, can you check the SSH command by running docker-machine --debug ssh default -vvv?

@nathanleclaire Just did and it fails, full log here

...

Using SSH client type: external
&{/usr/bin/ssh [/usr/bin/ssh -o PasswordAuthentication=no -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -o LogLevel=quiet -o ConnectionAttempts=3 -o ConnectTimeout=10 -o ControlMaster=no -o ControlPath=no [email protected] -o IdentitiesOnly=yes -i /Users/felipesabino/.docker/machine/machines/default/id_rsa -p 22 -vvv] []  <nil> <nil> <nil> [] <nil> <nil> <nil> <nil> false [] [] [] [] <nil>}
(default) DBG | }
OpenSSH_6.2p2, OSSLShim 0.9.8r 8 Dec 2011
debug1: Reading configuration data /Users/felipesabino/.ssh/config
debug1: /Users/felipesabino/.ssh/config line 37: Applying options for *
debug1: Reading configuration data /etc/ssh_config
debug1: /etc/ssh_config line 20: Applying options for *
debug1: Control socket "no" does not exist
debug2: ssh_connect: needpriv 0
debug1: Connecting to 127.0.0.1 [127.0.0.1] port 22.
debug2: fd 3 setting O_NONBLOCK
debug1: connect to address 127.0.0.1 port 22: Connection refused
debug1: Trying again...
debug1: Connecting to 127.0.0.1 [127.0.0.1] port 22.
debug2: fd 3 setting O_NONBLOCK
debug1: connect to address 127.0.0.1 port 22: Connection refused
debug1: Trying again...
debug1: Connecting to 127.0.0.1 [127.0.0.1] port 22.
debug2: fd 3 setting O_NONBLOCK
debug1: connect to address 127.0.0.1 port 22: Connection refused
ssh: connect to host 127.0.0.1 port 22: Connection refused
exit status 255

@nathanleclaire Oh and btw, thanks for looking it up :)

OK @felipesabino can you please try upgrading the Machine version to 0.5.6 and your VirtualBox version to 5.0.12 to see if the problem is resolved?

Would probably be worth rebooting your host computer as well.

Having the same issue with the versions you specified. Everything is fine until I reboot, deleting and recreating the default machine resolves the issue.

@nathanleclaire @seregasheypak

I just had the same problem with an almost clean OS X install, where the only thing copied from my old mac was my ~/.ssh folder.

After I removed it, everything worked as expected. I did not try tweaking my ~/.ssh/config params to know what exactly caused the issue, but based on my previous log showing debug1: /etc/ssh_config line 20: Applying options for * I am now very inclined to believe that one (or some) of the parameters was causing all these problems.

Here is my old ~/.ssh/config file as a reference for future diagnostics, if someone needs it.

Host *
  GSSAPIAuthentication no
  GSSAPIKeyExchange no
  PubkeyAuthentication no
  IdentitiesOnly yes

Same here on 10.11.3 (15D21), I thought a VirtualBox upgrade might fix it, but it didn't. _Don't remove your SSH configuration, that's ludicrous!_

What fixed it was also the suggestion by @nathanleclaire (Dec 10, 2015) to run:

$ docker-machine rm -f default && docker-machine --debug create -d virtualbox default

Then, to get your shell fully configured...

$ docker-machine env default
export DOCKER_TLS_VERIFY="1"
export DOCKER_HOST="tcp://192.168.99.101:2376"
export DOCKER_CERT_PATH="/Users/user/.docker/machine/machines/default"
export DOCKER_MACHINE_NAME="default"
# Run this command to configure your shell:
# eval $(docker-machine env default)

$ eval $(docker-machine env default)

You should now be able to run docker pull ... commands without a problem.

@globalcitizen agreed that nobody should remove their SSH configuration to be able to set up Docker/VirtualBox, but as you can see through my previous interactions, what fixed your problem did not work for me - https://github.com/docker/machine/issues/2240#issuecomment-170876751 and https://github.com/docker/machine/issues/2240#issuecomment-171471410 - even with the last VirtualBox version and, as _ludicrous_ as it might sound, removing my SSH config did work.

I had this problem, it turned out to be a corrupt ~/.ssh/config file on my mac. I had mapped my ~/.ssh folder to a container that had appended some stuff to the end of it without inserting a new line, causing a syntax error. Thanks to @felipesabino , I never would have found the issue without the info here!

Did the docker-machine rm default thing a couple times, but takes ages to download image.

Found a simpler workaround though! Open VirtualBox, turn off the "default" machine. Run Docker Quickstart and it starts up the VM and connects fine!

Just FYI everyone, if Docker Machine's implicit use of ~/.ssh/config is the underlying issue for the failures you're seeing, it should be finally put to rest once and for all in the 0.7.0 release since we just merged a fix to default the configuration to /dev/null (i.e. not to use a configuration file at all).

I don't have a ~/.ssh/config, but it still goes wrong with exit 255. Command executes is:

{[-o BatchMode=yes -o PasswordAuthentication=no -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -o LogLevel=quiet -o ConnectionAttempts=3 -o ConnectTimeout=10 -o ControlMaster=no -o ControlPath=none [email protected] -o IdentitiesOnly=yes -i /Volumes/Extern/Docker/Machine/machines/default/id_rsa -p 51788] /usr/bin/ssh}

This was produced by a clean docker-machine rm -f default && docker-machine --debug create -d virtualbox default on my Mac/OSX 10.11.4 with docker-machine 0.6.0/newest VBox.

@jurjevic Any chance I could get you to cobble together a SSH command directly based on that debug output and print the result of running it with -vvv (verbose mode)? It might help with debugging.

e.g:

$ /usr/bin/ssh -vvv -o BatchMode=yes -o PasswordAuthentication=no -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -o LogLevel=quiet -o ConnectionAttempts=3 -o ConnectTimeout=10 -o ControlMaster=no -o ControlPath=none [email protected] -o IdentitiesOnly=yes -i /Volumes/Extern/Docker/Machine/machines/default/id_rsa -p 51788
...

Make sure to set the port correctly.

Going to close this issue as it's veered off the rails from the original topic, but it's OK to keep posting here.

adding another scenario, just in case.
i had modified the vm settings to use more than 1 cpu
After rolling back that particular setting in virtualbox, everything worked as usual

I have a similar problem, where my docker-machine will loose its connection. When I first start it, it works fine, but sometime during the day it will loose the connection. To reconnect I have to kill the VM in VirtualBox and rerun the quickstart terminal.

I am using docker-machine.exe version 0.7.0, build a650a40 on Windows 10 with VirtualBox Version 5.0.16 r105871

image

Thanks for your help

same.

@justechn I have the same problem with you, have you fixed it ?

@chengjianhua-genedock I have not found a solution.

sad...I continue to find resolution, if you find out, please tell me,thanks ~

On Tue, Jul 19, 2016 at 3:35 AM +0800, "justechn" <[email protected]notifications@github.com> wrote:

@chengjianhua-genedockhttps://github.com/chengjianhua-genedock I have not found a solution.


You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHubhttps://github.com/docker/machine/issues/2240#issuecomment-233434300, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AThYAjxMz86ns5Elbot-_EbL9ZJDzsBwks5qW9V1gaJpZM4GfcHX.

I had fixed it by reinstall win10 preview to win10 pro.

Same problem, no IP...

Anyone hitting the "No IP" problem, you might wanna try uninstalling and re-installing VirtualBox specifically (restarting your host computer probably couldn't hurt either). I've hit quite a few issues unfortunately with upgrades not going super smoothly without this uninstall.

I face the no IP issue on a Windows 10 VM hosted in iMac.
Just to clarify, I am trying to setup docker in the Windows VM. Anyone facing similar issue?

Above from nathan doesn't change anything on windows 10. If I new what port windows should be connecting to the VM on I could just portmap it. How do I find that port? Is it the TCPIP one listed by netstat on the boot2docker? By the way on the retry under docker the console for boot2docker did not come up.

Cool. I had two network adapters for host only. Picking the other one helped. Then I ran into a connection failure that showed me the port so I port mapped it on the Network NAT. Don't know if that helped or not. Then I got some blather about certs not being correct and the helpful advise to regenerate them. Then lastly I got the information that on Windows 10 I need to run elevated to connect. So restarting quick start running as admin finally allowed a docker ps to get through. Hurray!

I had the same problem as @ghost above. Regarding virtualbox and more cores/CPU:s than one.

I have Mac Pro with 8 cores from 2008 that does only supports the Docker Toolbox and not the new Docker for mac. Using Virtualbox 5.2.6.

I tried to increase the number of cores of the virtual machine to 8 CPU:s to match my physical cores (docker-machine create -d virtualbox --virtualbox-cpu-count=8 default ). I noticed that the boot of the boot2docker was significantly when enabling more cores than one. Other forums confirms that this seems to be a problem with more cores and Virtualbox. This made the "Waiting for IP" part to timeout since the system never fully booted.

My solution was to use the Parallels driver instead of Virtualbox since I had Parallels Desktop already installed: https://github.com/Parallels/docker-machine-parallels . I created a machine with the maximum number of CPU:s

docker-machine create --driver=parallels --parallels-cpu-count -1 --parallels-memory 2048 parallels-docker

and then later starting the machine with:

docker-machine start parallels-docker ; eval "$(docker-machine env --shell=bash --no-proxy parallels-docker)"

Just restart : Docker Quickstart Terminal

It fixed the same problem for me

Worked like a charm

Was this page helpful?
0 / 5 - 0 ratings