I was setting up several MySQL databases using Vagrant for testing and I kept getting this Warning which was preventing me from using the VMs:
Warning: Authentication failure. Retrying...
After wasting lots of time and reading up on people's post I was able to get it working.
Work around steps:
go to this dir:
/opt/vagrant/embedded/gems/gems/vagrant-1.8.5/plugins/guests/linux/cap
vi public_key.rb (need to run as sudo)
Look for this code:
if test -f ~/.ssh/authorized_keys; then
grep -v -x -f '#{remote_path}' ~/.ssh/authorized_keys > ~/.ssh/authorized_keys.tmp
mv ~/.ssh/authorized_keys.tmp ~/.ssh/authorized_keys
Add this below that code:
chmod 0600 ~/.ssh/authorized_keys
End result will look like this:
Run "vagrant up" again

No comments:
Post a Comment