boot2docker / boot2docker

DEPRECATED; see https://github.com/boot2docker/boot2docker/pull/1408
https://github.com/boot2docker/boot2docker/pull/1408
Apache License 2.0
8.33k stars 1.29k forks source link

"boot2docker up" asking for password #405

Closed anderiv closed 10 years ago

anderiv commented 10 years ago

I recently upgraded (via homebrew) to boot2docker v1.0.0. Since doing this, boot2docker up has been asking for a password:

$  ~  boot2docker up
2014/06/20 10:19:16 Waiting for VM to be started...
...........docker@localhost's password:

The boot2docker disk image is v1.0.1.

Any clues as to why this might be happening?

Additionally, it appears that the docker daemon in the boot2docker disk is not listening on the port I've configured it to use:

$  ~  cat .boot2docker/profile
DOCKER_PORT=44243

$  ~  boot2docker ssh
...
docker@boot2docker:~$ sudo netstat -tunlp | grep docker
tcp        0      0 :::2375                 :::*                    LISTEN      632/docker

To add one more point of confusion here, the vbox port forwarding mappings are messed up as well:

screen shot 2014-06-20 at 10 39 22 am

Thank you!

SvenDowideit commented 10 years ago

This means you have not upgraded your vm (which unfortuanatly means deleting it and making a new one).

boot2docker up now connects using ssh to get the vm's IP address.

you need to:

boot2docker delete
boot2docker init

this will setup up the new port forwarding (which will be deprecated eventually) and creates an sshkey and adds it to the persistence drive.

bestes commented 10 years ago

Still asking for a password after I recreate the VM

Brians-MacBookAir:repos bestes$ boot2docker delete Brians-MacBookAir:repos bestes$ boot2docker init 2014/08/05 08:00:05 Creating VM boot2docker-vm... 2014/08/05 08:00:05 Apply interim patch to VM boot2docker-vm (https://www.virtualbox.org/ticket/12748) 2014/08/05 08:00:05 Setting NIC #1 to use NAT network... 2014/08/05 08:00:05 Port forwarding [ssh] tcp://127.0.0.1:2022 --> :22 2014/08/05 08:00:05 Port forwarding [docker] tcp://127.0.0.1:2375 --> :2375 2014/08/05 08:00:05 Setting NIC #2 to use host-only network "vboxnet0"... 2014/08/05 08:00:05 Setting VM storage... 2014/08/05 08:00:13 Done. Type boot2docker up to start the VM. Brians-MacBookAir:repos bestes$ boot2docker up 2014/08/05 08:00:18 Waiting for VM to be started... ......docker@localhost's password:

tianon commented 10 years ago

I ran into this issue and it turned out my iso was outdated; you could try a "boot2docker download" to grab the latest and give it another shot.

bestes commented 10 years ago

Bingo!

Thanks so much. BTW, just for anyone else searching for this issue, I did find the password ("tcuser") and was trying with that as well, but ran into all kinds of other problems. I had also tried boot2docker destroy && boot2docker init && boot2docker up with no luck.

SvenDowideit commented 10 years ago

boot2docker upgrade is being improved to help with this.

client9 commented 10 years ago

virgin install on Aug 23, mac os x 10.9.4

bash-3.2$ boot2docker upgrade
bash-3.2$ boot2docker delete
bash-3.2$ boot2docker init
bash-3.2$ boot2docker up
Waiting for VM and Docker daemon to start...
..................docker@localhost's password: 

any suggestions?

nickg

SvenDowideit commented 10 years ago

The ssh keys are created by boot2docker init if the 2 files ~/.ssh/id_boot2docker* don't exist. There are 3 things we can try:

1 run boot2docker -v up and see what the ssh command that is run is, then run that, adding -vvv to its cmdline 2 (this ones dumb, but I came across it on Linux today for the first time) ssh localhost and then run boot2docker up - I'm expecting there's something going wrong with the key agent, but I havn't had the energy to look into it yet 3 run rm ~/.ssh/id_boot2docker* && boot2docker delete && boot2docker -v init and make sure its creating a new ssh key, then boot2docker -v up

the biggest thing is - can you keep the output of those -v commands - that may give us hints.

client9 commented 10 years ago

Ahh the -v option. Didn't know about it.

$ boot2docker -v init
Using virtualbox driver
2014/08/24 09:22:53 executing: VBoxManage showvminfo boot2docker-vm --machinereadable
2014/08/24 09:22:53 executing: VBoxManage showvminfo boot2docker-vm --machinereadable
2014/08/24 09:22:53 executing: VBoxManage list vms
2014/08/24 09:22:53 executing: VBoxManage createvm --name boot2docker-vm --register
Virtual machine 'boot2docker-vm' is created and registered.
UUID: b1028fcf-45ac-47a4-b114-c7a9129dc99d
Settings file: '/Users/nickg/VirtualBox VMs/boot2docker-vm/boot2docker-vm.vbox'
2014/08/24 09:22:53 executing: VBoxManage showvminfo boot2docker-vm --machinereadable
2014/08/24 09:22:53 executing: VBoxManage setextradata boot2docker-vm VBoxInternal/CPUM/EnableHVP 1
2014/08/24 09:22:53 executing: VBoxManage modifyvm boot2docker-vm --firmware bios --bioslogofadein off --bioslogofadeout off --natdnshostresolver1 on --bioslogodisplaytime 0 --biosbootmenu disabled --ostype Linux26_64 --cpus 4 --memory 2048 --vram 8 --acpi on --ioapic on --rtcuseutc on --cpuhotplug off --pae on --longmode on --synthcpu off --hpet on --hwvirtex on --triplefaultreset off --nestedpaging on --largepages on --vtxvpid on --vtxux off --accelerate3d off --uart1 0x3F8 4 --uartmode1 server /Users/nickg/.boot2docker/boot2docker-vm.sock --boot1 dvd
2014/08/24 09:22:53 executing: VBoxManage showvminfo boot2docker-vm --machinereadable
2014/08/24 09:22:53 executing: VBoxManage modifyvm boot2docker-vm --nic1 nat --nictype1 virtio --cableconnected1 on
2014/08/24 09:22:53 executing: VBoxManage controlvm boot2docker-vm natpf1 ssh,tcp,127.0.0.1,2022,,22
2014/08/24 09:22:53 executing: VBoxManage list hostonlyifs
2014/08/24 09:22:53 executing: VBoxManage list dhcpservers
2014/08/24 09:22:53 executing: VBoxManage modifyvm boot2docker-vm --nic2 hostonly --nictype2 virtio --cableconnected2 on --hostonlyadapter2 vboxnet0
2014/08/24 09:22:53 executing: VBoxManage storagectl boot2docker-vm --name SATA --add sata --hostiocache on --bootable on
2014/08/24 09:22:53 executing: VBoxManage storageattach boot2docker-vm --storagectl SATA --port 0 --device 0 --type dvddrive --medium /Users/nickg/.boot2docker/boot2docker.iso
Converting from raw image file="stdin" to file="/Users/nickg/VirtualBox VMs/boot2docker-vm/boot2docker-vm.vmdk"...
Creating dynamic image with size 20971520000 bytes (20000MB)...
Initializing disk with ssh keys
WRITING: boot2docker, please format-me0000000000000000000000000000003500000000000014423 ustar0000000000000000boot2docker, please format-me.ssh0000700000000000000000000000000000000000000007767 5ustar0000000000000000.ssh/authorized_keys0000644000000000000000000000062100000000000013133 ustar0000000000000000ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCgykyA4OhwbXST5ZLIX+2dIIsPQgBKlxNyqhFzVI4ZtsxG+ht5NziJRoU10W1ujbmppmbUuefx5QMCQhcVNWsSqmdKLUEOBd3T2qkBjA6oayKWkMEOvC8hjGMmRCkzPwdf+B2dqcJX4U1uBqmHGhwZHM3Mu9EajzaxiSPVdU2Dk5FY8qzBuwpAudH0bhRDt0QmkhiY1wKE65A/ZxbLlX3i2jTpDZIj0swi82/OUbfuo5NxnUQMuY6vH+reYyL/z+AAzOOZVgL+aN8iv+gjrhPjmhTHDHPISs5tJ3y13LHOlAXO5DqBXdiV0LEQsinXgms0Xv3ANXgYWGqIYPz3aeoF client9@mac.local
.ssh/authorized_keys20000644000000000000000000000062100000000000013215 ustar0000000000000000ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCgykyA4OhwbXST5ZLIX+2dIIsPQgBKlxNyqhFzVI4ZtsxG+ht5NziJRoU10W1ujbmppmbUuefx5QMCQhcVNWsSqmdKLUEOBd3T2qkBjA6oayKWkMEOvC8hjGMmRCkzPwdf+B2dqcJX4U1uBqmHGhwZHM3Mu9EajzaxiSPVdU2Dk5FY8qzBuwpAudH0bhRDt0QmkhiY1wKE65A/ZxbLlX3i2jTpDZIj0swi82/OUbfuo5NxnUQMuY6vH+reYyL/z+AAzOOZVgL+aN8iv+gjrhPjmhTHDHPISs5tJ3y13LHOlAXO5DqBXdiV0LEQsinXgms0Xv3ANXgYWGqIYPz3aeoF client9@mac.local

-----
2014/08/24 09:23:00 executing: VBoxManage storageattach boot2docker-vm --storagectl SATA --port 1 --device 0 --type hdd --medium /Users/nickg/VirtualBox VMs/boot2docker-vm/boot2docker-vm.vmdk
nickg13:~ nickg$ boot2docker -v up
Using virtualbox driver
2014/08/24 09:23:07 executing: VBoxManage showvminfo boot2docker-vm --machinereadable
2014/08/24 09:23:07 executing: VBoxManage startvm boot2docker-vm --type headless
Waiting for VM "boot2docker-vm" to power on...
VM "boot2docker-vm" has been successfully started.
2014/08/24 09:23:07 executing: VBoxManage showvminfo boot2docker-vm --machinereadable
Waiting for VM and Docker daemon to start...
.Connecting to tcp://localhost:2022 (attempt #0).Connecting to tcp://localhost:2022 (attempt #0).Connecting to tcp://localhost:2022 (attempt #0).Connecting to tcp://localhost:2022 (attempt #0).Connecting to tcp://localhost:2022 (attempt #0).Connecting to tcp://localhost:2022 (attempt #0).Connecting to tcp://localhost:2022 (attempt #0).Connecting to tcp://localhost:2022 (attempt #0).Connecting to tcp://localhost:2022 (attempt #0).Connecting to tcp://localhost:2022 (attempt #0).Connecting to tcp://localhost:2022 (attempt #0).Connecting to tcp://localhost:2022 (attempt #0).Connecting to tcp://localhost:2022 (attempt #0).Connecting to tcp://localhost:2022 (attempt #0).Connecting to tcp://localhost:2022 (attempt #0).Connecting to tcp://localhost:2022 (attempt #0).Connecting to tcp://localhost:2022 (attempt #0).Connecting to tcp://localhost:2022 (attempt #0)2014/08/24 09:23:25 executing: /usr/bin/ssh ssh -o IdentitiesOnly=yes -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -o LogLevel=quiet -p 2022 -i /Users/nickg/.ssh/id_boot2docker docker@localhost ip addr show dev eth1
docker@localhost's password: 

First thing that jumps out is the key is set hostname (i.e. client9@mac.local) , but you are connecting to localhost. If I connect to the explicit hostname, it seems to work.

ssh -o IdentitiesOnly=yes -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -o LogLevel=quiet -p 2022 -i /Users/nickg/.ssh/id_boot2docker docker@mac.local

Then, it appears to succeed. Its quite possible my internal mac networking is non-standard due to various things installed and uninstalled.

Thoughts?

nickg

client9 commented 10 years ago

Hmm, github formatting obscures it. scroll way right to see for ssh key "client@mac.local"... also the SSH connection attempt count doesnt increment and maybe could use a line break.

onward!

jdgomeza commented 10 years ago

I had the same problem, delete/download/init did not resolved the problem for me.

I opened VBox UI and found I had an outdated Extension pack. After I installed the new version, the keys were finally generated. I had VBox UI installed before so maybe there was conflict.

bash-3.2$ boot2docker delete
bash-3.2$ boot2docker init
Generating public/private rsa key pair.
Your identification has been saved in /Users/javier.gomez/.ssh/id_boot2docker.
Your public key has been saved in /Users/javier.gomez/.ssh/id_boot2docker.pub.

Hope that helps

pditommaso commented 10 years ago

No way. I've tried everything explained here, but boot2docker init refuses to create the SSH key pair.

SvenDowideit commented 10 years ago

@pditommaso there seems to have been an issue with brew, so if you installed using it, please update again.

jheintz commented 10 years ago

Why is this issue closed? I'm getting the problem with a fresh brew update && brew upgrade.

~ $ boot2docker version
Client version: v1.2.0
Git commit: 22b11f1
~ $ boot2docker delete
~ $ boot2docker download
Downloading boot2docker ISO image...
Latest release is v1.2.0
Success: downloaded https://github.com/boot2docker/boot2docker/releases/download/v1.2.0/boot2docker.iso
    to /Users/jheintz/.boot2docker/boot2docker.iso
~ $ boot2docker -v init
Using virtualbox driver
2014/09/02 12:12:33 executing: VBoxManage showvminfo boot2docker-vm --machinereadable
2014/09/02 12:12:33 executing: VBoxManage list vms
2014/09/02 12:12:33 executing: VBoxManage createvm --name boot2docker-vm --register
Virtual machine 'boot2docker-vm' is created and registered.
UUID: 43908ce0-f559-42ed-a13d-5866b7200279
Settings file: '/Users/jheintz/VirtualBox VMs/boot2docker-vm/boot2docker-vm.vbox'
2014/09/02 12:12:33 executing: VBoxManage showvminfo boot2docker-vm --machinereadable
2014/09/02 12:12:33 executing: VBoxManage setextradata boot2docker-vm VBoxInternal/CPUM/EnableHVP 1
2014/09/02 12:12:33 executing: VBoxManage modifyvm boot2docker-vm --firmware bios --bioslogofadein off --bioslogofadeout off --natdnshostresolver1 on --bioslogodisplaytime 0 --biosbootmenu disabled --ostype Linux26_64 --cpus 4 --memory 2048 --vram 8 --acpi on --ioapic on --rtcuseutc on --cpuhotplug off --pae on --longmode on --synthcpu off --hpet on --hwvirtex on --triplefaultreset off --nestedpaging on --largepages on --vtxvpid on --vtxux off --accelerate3d off --uart1 0x3F8 4 --uartmode1 server /Users/jheintz/.boot2docker/boot2docker-vm.sock --boot1 dvd
2014/09/02 12:12:33 executing: VBoxManage showvminfo boot2docker-vm --machinereadable
2014/09/02 12:12:33 executing: VBoxManage modifyvm boot2docker-vm --nic1 nat --nictype1 virtio --cableconnected1 on
2014/09/02 12:12:33 executing: VBoxManage controlvm boot2docker-vm natpf1 ssh,tcp,127.0.0.1,2022,,22
2014/09/02 12:12:33 executing: VBoxManage list hostonlyifs
2014/09/02 12:12:33 executing: VBoxManage list dhcpservers
2014/09/02 12:12:33 executing: VBoxManage modifyvm boot2docker-vm --nic2 hostonly --nictype2 virtio --cableconnected2 on --hostonlyadapter2 vboxnet0
2014/09/02 12:12:34 executing: VBoxManage storagectl boot2docker-vm --name SATA --add sata --hostiocache on --bootable on
2014/09/02 12:12:34 executing: VBoxManage storageattach boot2docker-vm --storagectl SATA --port 0 --device 0 --type dvddrive --medium /Users/jheintz/.boot2docker/boot2docker.iso
error in run: Failed to initialize machine "boot2docker-vm": open /Users/jheintz/.ssh/id_boot2docker.pub: no such file or directory
~ $
SvenDowideit commented 10 years ago

thats not the correct version. you should have:

bash-3.2$ boot2docker version
Client version: v1.2.0
Git commit: a551732

I'm told that brew has updated their version to correct this.

jheintz commented 10 years ago

Thanks @SvenDowideit, working now.

I needed to

brew remove boot2docker
brew install boot2docker

and then I got that version number.

constfun commented 10 years ago

I had to manually delete existing id_boot2docker and id_boot2docker.pub files before running boot2docker init to make it work.

njt1982 commented 10 years ago

Removing boot2docker, updating brew and resintalling fixed the SSH issue for me too.

gabrielstein commented 9 years ago

Well, what solved to me, and I think that more people can use it. If you already had boot2docker installed(using brew), do that:

enjalot commented 9 years ago

on a brand new mac with a fresh install of 1.3.1 and homebrew i had this problem. I was able to fix it by following the other issue and confirming that the ssh keys were generated with the wrong permissions

chmod go-r ~/.ssh/id_boot2docker

ahknight commented 9 years ago

I just experienced what @enjalot did: after removing/reinstalling everything the SSH keys in .ssh were 0644. I set them to 0400 and it booted just fine.

Everything was installed on OS X 10.10 via the latest Homebrew.

$ boot2docker version
Boot2Docker-cli version: v1.3.1
Git commit: 57ccdb8
tianon commented 9 years ago

I'd really, really like to move those into "~/.boot2docker" so that the boot2docker state is closer to being self-contained.

Maybe we have it check whether "~/.ssh/idboot2docker" exists, and use that if it does, but otherwise default to "~/.boot2docker/idrsa", so that new users get the newer path.

My ultimate goal is that the clean-slate "start over" procedure for boot2docker can be as simple as "make sure the VM is stopped and purge ~/.boot2docker".

SvenDowideit commented 9 years ago

mmm, that aligns somewhat with how docker hosts throws everything into ~/.docker/hostname/

but does result in non-shared iso files, meaning you re-re-re-download the same one

Quexer69 commented 9 years ago

just btw... I run into this right now. Just tried PW docker on boot2docker upgrade and it works ->

MacBook-Pro-2:p4-app cstebe$ boot2docker upgrade
Latest release for boot2docker/boot2docker is v1.3.1
Downloading boot2docker ISO image...
Success: downloaded https://github.com/boot2docker/boot2docker/releases/download/v1.3.1/boot2docker.iso
        to /Users/cstebe/.boot2docker/boot2docker.iso
Waiting for VM and Docker daemon to start...
.........docker@localhost's password: 
.o
Started.
Writing /Users/cstebe/.boot2docker/certs/boot2docker-vm/ca.pem
Writing /Users/cstebe/.boot2docker/certs/boot2docker-vm/cert.pem
Writing /Users/cstebe/.boot2docker/certs/boot2docker-vm/key.pem

To connect the Docker client to the Docker daemon, please set:
    export DOCKER_HOST=tcp://192.168.59.104:2376
    export DOCKER_CERT_PATH=/Users/cstebe/.boot2docker/certs/boot2docker-vm
    export DOCKER_TLS_VERIFY=1

MacBook-Pro-2:p4-app cstebe$

added the exports to my .bash_profile and boot2docker start

fotinakis commented 9 years ago

I had to clear my entire local config to fix this, and it worked:

boot2docker delete
rm -rf ~/.boot2docker/ ~/.ssh/id_boot2docker*
boot2docker init
boot2docker up
ghost commented 9 years ago

I encountered this issue after running boot2docker on my Mac with mixed users. Here's what I've observed:

1) Installed boot2docker as the user "slack"; used it happily for some time

2) Began using boot2docker as the user "tony"; noticed numerous password prompts

3) Found this page. Multiple rounds of delete/download/init/etc.

4) Eventually SSH'd into the virtualbox VM to check out which public key is trusted.

5) Noticed that the authorized_keys contains a pubkey that was generated for "slack@localhost" -- yet the last time I performed an init, I was the user tony@localhost!!

I'm not quite sure how it's happening, but clearly, when boot2docker initializes the VM, it's grabbing the public key of the original user. Easy enough for me to copy slack's keys into tony's .ssh dir, now that I grok the issue.

dixon1e commented 9 years ago

I'm trying with image 1.3.2 and getting error:

"The host network interface with the given name could not be found."

I have tried everything listed above here. Removing id_boot2docker, fixing .ssh permissions, removing the .boot2docker directory, etc. etc.

I also upgraded virtualbox to 4.3.20. This seems to be network related somehow? Running on Mac Os X 10.8.5.

Here is the full boot2docker -v init output:

2014/11/28 21:06:08 executing: VBoxManage hostonlyif ipconfig dyld: DYLD_ environment variables being ignored because main executable (/Applications/VirtualBox.app/Contents/MacOS/VBoxNetAdp --ip 192.168.59.3 --netmask 255.255.255.0 VBoxManage: error: The host network interface with the given name could not be found VBoxManage: error: Details: code NS_ERROR_INVALIDARG (0x80070057), component Host, interface IHost, callee nsISupports VBoxManage: error: Context: "FindHostNetworkInterfaceByName(name.raw(), hif.asOutParam())" at line 218 of file VBoxManageHostonly.cpp VBoxManage: error: Could not find interface 'dyld: DYLD environment variables being ignored because main executable (/Applications/VirtualBox.app/Contents/MacOS/VBoxNetAdp' error in run: Failed to initialize machine "boot2docker-vm": exit status 2

chesleybrown commented 9 years ago

@fotinakis Thank you. rm -rf ~/.boot2docker/ ~/.ssh/id_boot2docker* was the key for me.

xcolwell commented 9 years ago

I'm seeing this problem on OS X 10.10.1 repeatedly when using docker installed via

brew cask install virtualbox
brew install docker
brew install boot2docker

I've found the root cause in my case, which is the permissions of the docker private key get changed to u=rw,go=r, causing SSH to avoid using it (it requires that the private key be readable by the user only).

ls -lah ~/.ssh/id_boot2docker
-rw-------@ 1 brien  staff   1.6K Jan  9 12:30 /Users/brien/.ssh/id_boot2docker
ls -lah ~/.ssh/id_boot2docker.bad
-rw-r--r--@ 1 brien  staff   1.6K Jan  8 22:42 /Users/brien/.ssh/id_boot2docker.bad

Fixing the permissions can be done with chmod u=rw,go= ~/.ssh/id_boot2docker.

Usually nothing touches my private keys, so I'm wondering if there's a check in boot2docker or some startup script that updates the permissions erroneously?

I reset the permissions in my own init script for now.

tj commented 9 years ago

rm -rf ~/.boot2docker/ ~/.ssh/id_boot2docker* did it for me as well

mgijsberti commented 9 years ago

This worked for me: boot2docker delete rm -rf ~/.boot2docker/ ~/.ssh/id_boot2docker* boot2docker init boot2docker up

strogonoff commented 9 years ago

In case anyone else happen to come across this even with the latest version of boot2docker, make sure you don’t have the VM running under another user account on the same machine simultaneously.

As a side note, even after stopping boot2docker VM under first account I still haven’t been able so far to work with Docker from the second account. The VM takes much longer to start for some reason and after that docker client is not able to connect to it, throwing up with an “i/o timeout” error.

RomanSaveljev commented 9 years ago

The other issue with running boot2docker concurrently under different accounts is https://github.com/boot2docker/boot2docker-cli/issues/337

mcqj commented 9 years ago

This is still a problem in boot2docker 1.5.0

ghost commented 9 years ago

I had the same issue caused by PreferredAuthentications password,keyboard-interactive,publickey under Host * in ~/.ssh/config

karlingen commented 9 years ago

+1

garthk commented 9 years ago

+1 @enjalot:

chmod go-r ~/.ssh/id_boot2docker

Strikes me quite reasonable that boot2docker could check that and/or fix it.

dbkaplun commented 9 years ago

boot2docker shouldn't need to auth using an SSH key to connect to localhost. Maybe we should consider turning auth off completely in the VM's SSH daemon, and this issue would go away for free.

metakermit commented 9 years ago

OK, for me moving the old .ssh/id_boot2docker* files to a different folder and then running the sequence helped:

boot2docker delete
boot2docker download
boot2docker -v init
boot2docker start
MartinSeeler commented 9 years ago

I had this issue caused by my ./ssh/config seetings to auto-copy zsh settings to remote by

Host *
   PermitLocalCommand yes
   LocalCommand tar c -C${HOME} .oh-my-zsh .zshrc .vim .vimrc | ssh -o PermitLocalCommand=no %n "tar mx -C${HOME} ; chsh -s /bin/zsh"

Removing these settings fixed it for me.

thekarel commented 9 years ago

I had to change the VirtualBox settings to not have a space in Default Machine Folder path:

screen shot 2015-04-14 at 11 38 16

Before this, running boot2docker -v init gave me

VBoxManage: error: Invalid UUID or filename "/Users/x/VirtualBox VMs/boot2docker-vm/boot2docker-vm.vmdk"
error in run: Failed to initialize machine "boot2docker-vm": exit status 1

Using docker and boot2docker 1.5.0 via brew

(based on @jerrymf https://github.com/boot2docker/osx-installer/issues/106#issuecomment-87893137)

subfuzion commented 9 years ago

I was tearing my hair out for a while on this one. Nothing seemed to work, including everything mentioned in this thread. I had completely removed everything (.boot2docker/, ./ssh/id_boot2docker*, /usr/bin/local/boot2docker, VirtualBox VMs/boot2docker-vm/, VirtualBox application) and still couldn't fix. Installing latest version of boot2docker (1.5.0) didn't help, installing the latest VirtualBox (4.3.26) didn't help ...

Finally, I opened the VirtualBox GUI and explicitly deleted all previous appliances (including boot2docker-vm and one I had renamed to 'dev'), and that finally did the trick. Argh. Hope this helps someone else.

swogger commented 9 years ago

Solution: As strange as it may sound you need to enter the password "tcuser" at least 4 times. Makes no sense but it works.

toddlers commented 9 years ago

@swogger I've done that as well but no help :( finally ran fours magic commands

boot2docker delete
rm -rf ~/.boot2docker/ ~/.ssh/id_boot2docker*
boot2docker init
boot2docker up

Worked fine :)

shaimr commented 9 years ago

Thanks @toddlers, it worked for me :+1:

nerab commented 9 years ago

Finally ... rm -rf ~/.boot2docker/ ~/.ssh/id_boot2docker* did the trick. Thanks, @toddlers!

beetree commented 9 years ago

Had the same error on fresh install following the exact instructions on https://docs.docker.com/installation/mac/

Reboot of the host machine solved my issue.

tylercloke commented 9 years ago

@toddlers black magic was effective.

eduardopelitti commented 9 years ago

@toddlers solution worked for me too. Thanks!