New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Got vagrant@127.0.0.1: Permission denied (publickey). message after upgrade to 2.3.4 #13027
Comments
Hi there, Would you please provide a minimal Vagrantfile which reproduces the behavior you are experiencing along with a gist of the debug output from a failed Thanks! |
# -*- mode: ruby -*-
# vi: set ft=ruby :
Vagrant.configure("2") do |config|
config.vm.box = "ubuntu/jammy64"
config.vm.network "private_network", ip: "10.10.10.22"
config.vm.synced_folder "./data", "/data"
config.vm.provider "virtualbox" do |vb|
vb.memory = "1024"
vb.name = "ubuntu22"
end
end Just simply, as I said, the permission issue started after upgrading to 2.3.4, all my VM have that message, so I think it's nothing to do with the Vagrantfile, and it's happened on three of my pc with two windows 10 and one windows 11, so I think it's nothing to do with the OS too. |
I've seen the same behavior, but I don't think it's a Vagrant issue. I think it's due to a fairly recent update to OpenSSH on Windows. The latest version of OpenSSH on Windows doesn't trust private keys/identity files unless they're accessible ONLY by the user running the command. So, unless the Vagrantfile is somewhere under your user profile (usually From the output of To fix this, you can either move the To use Vagrant's embedded ssh, set the I hope this helps. |
|
@chan15 Excellent! I'm glad it's working now. @chrisroberts Although this isn't really a Vagrant issue, it's likely to affect a lot of people. It'd be good to address it in the documentation. |
@PaulNeumann 👍 i'm also having a look to see if we can include a permission check so we can surface an actionable error message |
Thanks for your contribution. :) |
Three of my computers, Windows 11 x 1 and Windows 10 x 2 all got this message after upgrading vagrant to 2.3.4, even downgrading back to 2.3.3 it's still there.
VirtualBox version: 7.0.4
vagrant ssh --debug
got:If I set
config.ssh.insert_key = false
then I can access the VM, but I want everything back to normal just like before.It's happened in several different versions of Ubuntu and Centos with basic config, so I think I don't need to give the
Vagrantfile
.The text was updated successfully, but these errors were encountered: