Your suggestion to change 'config.ssh.insert_key' from False to True (or 
delete it altogether as True is the default) resolved the problem.  I'm 
sure that I began setting this to False sometime in the past because doing 
so fixed some other error I was getting but I can't find anything in my 
notes to explain why I did it.  In any case, things are working now so 
thanks!

On Wednesday, May 15, 2019 at 12:06:49 PM UTC-7, Robert wrote:
>
> I'm running Vagrant v. 2.2.3 on top of VirtualBox 5.2.26 on macOS
> 10.12.6.  Whenever I tried to create Debian VMs, I'm getting an
> authentication error.  Here is my Vagrantfile:
>
>     # -*- mode: ruby -*-
>
>
>     VAGRANTFILE_API_VERSION = "2"
>
>
>     Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
>       config.vm.box = "debian/stretch64"
>       config.ssh.insert_key = false
>       config.vm.synced_folder "./shared", "/vagrant", type: "virtualbox"
>       config.vm.provider :virtualbox do |v|
>         v.memory = 256
>         v.linked_clone = true
>       end
>
>
>       config.vm.define "fs" do |fs|
>         fs.vm.hostname = "fs-vm.example.com"
>         fs.vm.network :private_network, ip: "192.168.2.100"
>       end
>
>
>       config.vm.define "db" do |db|
>         db.vm.hostname = "db-vm.example.com"
>         db.vm.network :private_network, ip: "192.168.2.101"
>       end
>
>
>       config.vm.define "web" do |web|
>         web.vm.hostname = "web-vm.example.com"
>         web.vm.network :private_network, ip: "192.168.2.102"
>         web.ssh.forward_agent = true
>       end
>
>
>       config.vm.define "cms" do |cms|
>         cms.vm.hostname = "cms-vm.example.com"
>         cms.vm.network :private_network, ip: "192.168.2.103"
>       end
>     end
>
>
> The first time I ran 'vagrant up', I got errors just like those shown
> below except that I got the "Warning: Authentication failure" errors
> repeatedly for the 'fs' server.  When I re-run 'vagrant up', I now get
> the errors as they are shown below.
>
>     Bringing machine 'fs' up with 'virtualbox' provider...
>     Bringing machine 'db' up with 'virtualbox' provider...
>     Bringing machine 'web' up with 'virtualbox' provider...
>     Bringing machine 'cms' up with 'virtualbox' provider...
>     ==> fs: Machine already provisioned. Run `vagrant provision` or use 
> the `--provision`
>     ==> fs: flag to force provisioning. Provisioners marked to run always 
> will still run.
>     ==> db: Clearing any previously set forwarded ports...
>     ==> db: Fixed port collision for 22 => 2222. Now on port 2201.
>     ==> db: Clearing any previously set network interfaces...
>     ==> db: Preparing network interfaces based on configuration...
>         db: Adapter 1: nat
>         db: Adapter 2: hostonly
>     ==> db: Forwarding ports...
>         db: 22 (guest) => 2201 (host) (adapter 1)
>     ==> db: Running 'pre-boot' VM customizations...
>     ==> db: Booting VM...
>     ==> db: Waiting for machine to boot. This may take a few minutes...
>         db: SSH address: 127.0.0.1:2201
>         db: SSH username: vagrant
>         db: SSH auth method: private key
>         db: Warning: Authentication failure. Retrying...
>         db: Warning: Authentication failure. Retrying...
>         db: Warning: Authentication failure. Retrying...
>         db: Warning: Authentication failure. Retrying...
>         db: Warning: Authentication failure. Retrying...
>
>
> If I run 'vagrant status' I see the following:
>
>     Current machine states:
>
>
>     fs                        running (virtualbox)
>     db                        running (virtualbox)
>     web                       poweroff (virtualbox)
>     cms                       poweroff (virtualbox)
>
>
>     This environment represents multiple VMs. The VMs are all listed
>     above with their current state. For more information about a specific
>     VM, run `vagrant status NAME`.
>
>
> Is there any way to prevent this authentication error so that when I
> issue the 'up' command all four VMs will build without errors?  Vagrant
> seems like a very handy development tool but I always have this problem
> whenever I try to use it.
>
> Thanks!
>
>

-- 
This mailing list is governed under the HashiCorp Community Guidelines - 
https://www.hashicorp.com/community-guidelines.html. Behavior in violation of 
those guidelines may result in your removal from this mailing list.

GitHub Issues: https://github.com/mitchellh/vagrant/issues
IRC: #vagrant on Freenode
--- 
You received this message because you are subscribed to the Google Groups 
"Vagrant" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vagrant-up/1a96e476-885b-4080-be5b-944eaa5f9a92%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to