Until you figure out the issue, you can try the workaround in this comment. https://github.com/mitchellh/vagrant/issues/5059#issuecomment-68041037
Basically config.ssh.insert_key = false into your Vagrantfile should prevent it from changing the keys, which means it will keep using the old one. For your issue it sounds like the place that vagrant is trying to store the new private key file has too loose of permissions, so you need to chmod the .ssh folder that they live in to 600, which the .pub being 644 permissions. On Sunday, April 12, 2015 at 8:55:18 PM UTC-5, Monte Milanuk wrote: > > So... I've played with vagrant a very little bit in the past. Decided to > renew the acquaintance, and downloaded a new .deb for the current version > and installed it to my laptop (running Ubuntu 14.04). Following the > 'Getting Started' guide @ vagrantup.com... all goes well up until this > point: > > ==> default: Waiting for machine to boot. This may take a few minutes... > default: SSH address: 127.0.0.1:2222 > default: SSH username: vagrant > default: SSH auth method: private key > default: > default: Vagrant insecure key detected. Vagrant will automatically > replace > default: this with a newly generated keypair for better security. > default: > default: Inserting generated public key within guest... > default: Removing insecure key from the guest if its present... > default: Key inserted! Disconnecting and reconnecting using new SSH > key... > The private key to connect to the machine via SSH must be owned > by the user running Vagrant. This is a strict requirement from > SSH itself. Please fix the following key to be owned by the user > running Vagrant: > > > /srv/data/VirtualBox/vagrant/test/.vagrant/machines/default/virtualbox/ > private_key > monte@machin-shin:/srv/data/VirtualBox/vagrant/test$ > > > Now... I've tried changing the permissions on that file... no go, either > as a user or as root. I'm pretty fuzzy on what/where else I should be > editing to address the problem. Did some digging around on StackOverflow, > Reddit, etc. and saw some things that were close - apparently some stuff > changed with the release of 1.7.x regarding ssh... all well and fine, but > the basic intro tutorial makes *no* mention of anything that needs to be > done differently, or what this 'fix' I'm supposed to do even looks like, > leaving a new user (me) kind of high and dry. Do I edit the VagrantFile in > the directory where I'm storing/running the box, or some file buried under > ~/.vagrant.d, or both? Right now I'm still stuck, so if someone could > kindly point me in the right direction, I'd greatly appreciate it. > > Thanks, > > Monte > -- 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]. For more options, visit https://groups.google.com/d/optout.
