Discussion:
[vagrant-up] Linux Vagrant in WSL env doesn't detect VBoxManage.exe which is in $PATH
Lukas
2018-10-17 18:36:12 UTC
Permalink
So I followed the guide on https://www.vagrantup.com/docs/other/wsl.html
which seems fairly straight forward.
I'm using Virtualbox on the Windows Host. I've got Vagrant 2.1.5 installed
both in the WSL Debian environment as well as the Windows environment.
I've exported VAGRANT_WSL_ENABLE_WINDOWS_ACCESS="1" in the Linux env and
made sure that VBoxManage.exe is in the PATH of that environment as well.

Vagrant in Windows works as one would expect. Executing Vagrant on Linux
doesn't find the VBoxManage.exe executable, even though it's in the path.

In WSL I'm using /c/Users/lukas as my home directory, so that I have a
shared Linux/Windows home dir. I have metadata turned on and root = / in
/etc/wsl.conf (which is why the path is /c/ instead of the /mnt/c/ default)
so that Linux permissions are carried over to the NTFS filesystem.

In ~/test/ (which is /c/Users/lukas/test/ or C:\Users\lukas\test) I have a
default Vagrantfile with a centos/7 box.

VBoxManage.exe is in my PATH:

***@bigmac:~/test$ which VBoxManage.exe
/c/Program Files/Oracle/VirtualBox/VBoxManage.exe

However vagrant up will result in

***@bigmac:~/test$ vagrant up
No usable default provider could be found for your system.

Vagrant relies on interactions with 3rd party systems, known as
"providers", to provide Vagrant with resources to run development
environments. Examples are VirtualBox, VMware, Hyper-V.

The easiest solution to this message is to install VirtualBox, which
is available for free on all major platforms.

If you believe you already have a provider available, make sure it
is properly installed and configured. You can see more details about
why a particular provider isn't working by forcing usage with
`vagrant up --provider=PROVIDER`, which should give you a more specific
error message for that particular provider.


I can however use vagrant.exe up and it'll work just fine

***@bigmac:~/test$ vagrant.exe up
Bringing machine 'default' up with 'virtualbox' provider...
==> default: Importing base box 'centos/7'...
==> default: Matching MAC address for NAT networking...
==> default: Checking if box 'centos/7' is up to date...
==> default: Setting the name of the VM: test_default_1539801180834_58779
==> default: Clearing any previously set network interfaces...
==> default: Preparing network interfaces based on configuration...
default: Adapter 1: nat
==> default: Forwarding ports...
default: 22 (guest) => 2222 (host) (adapter 1)
==> default: Booting VM...
==> 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 it's present...
default: Key inserted! Disconnecting and reconnecting using new SSH
key...
==> default: Machine booted and ready!
==> default: Checking for guest additions in VM...
default: No guest additions were detected on the base box for this VM!
Guest
default: additions are required for forwarded ports, shared folders,
host only
default: networking, and more. If SSH fails on this machine, please
install
default: the guest additions and repackage the box to continue.
default:
default: This is not an error message; everything may continue to work
properly,
default: in which case you may ignore this message.
==> default: Rsyncing folder: /cygdrive/c/Users/lukas/test/ => /vagrant
***@bigmac:~/test$

However using vagrant.exe instead of the Linux vagrant binary obviously
means that the permissions for the ssh key are Windows defaults i.e. world
readable.

Any idea what else I'd have to change other than setting that
VAGRANT_WSL_ENABLE_WINDOWS_ACCESS environment variable to make Linux
Vagrant detect VBoxManage.exe from the Windows environment?

Thanks,
-- Lukas
--
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 vagrant-up+***@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/8c42e4a0-1c5e-4e81-9bcf-d349dcbeb338%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Lukas
2018-10-17 18:53:07 UTC
Permalink
I just tested again on 2.2.0 but same result

***@bigmac:~/test$ vagrant destroy
The provider 'virtualbox' that was requested to back the machine
'default' is reporting that it isn't usable on this system. The
reason is shown below:

Vagrant could not detect VirtualBox! Make sure VirtualBox is properly
installed.
Vagrant uses the `VBoxManage` binary that ships with VirtualBox, and
requires
this to be available on the PATH. If VirtualBox is installed, please find
the
`VBoxManage` binary and add it to the PATH environmental variable.

***@bigmac:~/test$ which VBoxManage.exe
/c/Program Files/Oracle/VirtualBox/VBoxManage.exe

***@bigmac:~/test$ echo $VAGRANT_WSL_ENABLE_WINDOWS_ACCESS
1
--
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 vagrant-up+***@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/1d1f2932-991e-48be-bf20-61b6ee6b5a7d%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Lukas
2018-10-18 10:18:20 UTC
Permalink
I've been looking at the usage of VAGRANT_WSL_ENABLE_WINDOWS_ACCESS and it
seems there's some logging early on in def wsl_init():
logger.warn("Windows Subsystem for Linux detected. Allowing
access to user: #{shared_user}")

However when I run vagrant with debug output there's no such line being
logged. Now looking into why. If anyone has an idea of something I might
have misconfigured or misunderstood please let me know.

Here's a complete run log:
***@bigmac:~/salt-ssh-test$ VAGRANT_LOG=debug vagrant up
INFO global: Vagrant version: 2.2.0
INFO global: Ruby version: 2.4.4
INFO global: RubyGems version: 2.6.14.1
INFO global: VAGRANT_WSL_ENABLE_WINDOWS_ACCESS="1"
INFO global: VAGRANT_LOG="debug"
INFO global: VAGRANT_INSTALLER_ENV="1"
INFO global:
VAGRANT_EXECUTABLE="/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/bin/vagrant"
INFO global: VAGRANT_INSTALLER_VERSION="2"
INFO global: VAGRANT_INSTALLER_EMBEDDED_DIR="/opt/vagrant/embedded"
WARN global: resolv replacement has not been enabled!
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/box/plugin.rb
INFO manager: Registered plugin: box command
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/cap/plugin.rb
INFO manager: Registered plugin: cap command
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/cloud/plugin.rb
INFO manager: Registered plugin: vagrant-cloud
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/destroy/plugin.rb
INFO manager: Registered plugin: destroy command
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/global-status/plugin.rb
INFO manager: Registered plugin: global-status command
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/halt/plugin.rb
INFO manager: Registered plugin: halt command
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/help/plugin.rb
INFO manager: Registered plugin: help command
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/init/plugin.rb
INFO manager: Registered plugin: init command
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/list-commands/plugin.rb
INFO manager: Registered plugin: list-commands command
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/login/plugin.rb
INFO manager: Registered plugin: vagrant-login
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/package/plugin.rb
INFO manager: Registered plugin: package command
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/plugin/plugin.rb
INFO manager: Registered plugin: plugin command
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/port/plugin.rb
INFO manager: Registered plugin: port command
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/powershell/plugin.rb
INFO manager: Registered plugin: powershell command
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/provider/plugin.rb
INFO manager: Registered plugin: provider command
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/provision/plugin.rb
INFO manager: Registered plugin: provision command
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/push/plugin.rb
INFO manager: Registered plugin: push command
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/rdp/plugin.rb
INFO manager: Registered plugin: rdp command
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/reload/plugin.rb
INFO manager: Registered plugin: reload command
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/resume/plugin.rb
INFO manager: Registered plugin: resume command
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/snapshot/plugin.rb
INFO manager: Registered plugin: snapshot command
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/ssh/plugin.rb
INFO manager: Registered plugin: ssh command
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/ssh_config/plugin.rb
INFO manager: Registered plugin: ssh-config command
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/status/plugin.rb
INFO manager: Registered plugin: status command
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/suspend/plugin.rb
INFO manager: Registered plugin: suspend command
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/up/plugin.rb
INFO manager: Registered plugin: up command
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/upload/plugin.rb
INFO manager: Registered plugin: upload command
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/validate/plugin.rb
INFO manager: Registered plugin: validate command
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/version/plugin.rb
INFO manager: Registered plugin: version command
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/winrm/plugin.rb
INFO manager: Registered plugin: winrm command
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/winrm_config/plugin.rb
INFO manager: Registered plugin: winrm-config command
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/communicators/ssh/plugin.rb
INFO manager: Registered plugin: ssh communicator
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/communicators/winrm/plugin.rb
INFO manager: Registered plugin: winrm communicator
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/communicators/winssh/plugin.rb
INFO manager: Registered plugin: windows ssh communicator
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/alt/plugin.rb
INFO manager: Registered plugin: ALT Platform guest
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/amazon/plugin.rb
INFO manager: Registered plugin: Amazon Linux guest
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/arch/plugin.rb
INFO manager: Registered plugin: Arch guest
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/atomic/plugin.rb
INFO manager: Registered plugin: Atomic Host guest
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/bsd/plugin.rb
INFO manager: Registered plugin: BSD-based guest
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/coreos/plugin.rb
INFO manager: Registered plugin: CoreOS guest
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/darwin/plugin.rb
INFO manager: Registered plugin: Darwin guest
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/debian/plugin.rb
INFO manager: Registered plugin: Debian guest
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/dragonflybsd/plugin.rb
INFO manager: Registered plugin: DragonFly BSD guest
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/elementary/plugin.rb
INFO manager: Registered plugin: Elementary guest
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/esxi/plugin.rb
INFO manager: Registered plugin: ESXi guest.
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/fedora/plugin.rb
INFO manager: Registered plugin: Fedora guest
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/freebsd/plugin.rb
INFO manager: Registered plugin: FreeBSD guest
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/funtoo/plugin.rb
INFO manager: Registered plugin: Funtoo guest
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/gentoo/plugin.rb
INFO manager: Registered plugin: Gentoo guest
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/haiku/plugin.rb
INFO manager: Registered plugin: Haiku guest
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/kali/plugin.rb
INFO manager: Registered plugin: Kali guest
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/linux/plugin.rb
INFO manager: Registered plugin: Linux guest.
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/mint/plugin.rb
INFO manager: Registered plugin: Mint guest
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/netbsd/plugin.rb
INFO manager: Registered plugin: NetBSD guest
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/nixos/plugin.rb
INFO manager: Registered plugin: NixOS guest
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/omnios/plugin.rb
INFO manager: Registered plugin: OmniOS guest.
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/openbsd/plugin.rb
INFO manager: Registered plugin: OpenBSD guest
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/photon/plugin.rb
INFO manager: Registered plugin: VMware Photon guest
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/pld/plugin.rb
INFO manager: Registered plugin: PLD Linux guest
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/redhat/plugin.rb
INFO manager: Registered plugin: Red Hat Enterprise Linux guest
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/slackware/plugin.rb
INFO manager: Registered plugin: Slackware guest
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/smartos/plugin.rb
INFO manager: Registered plugin: SmartOS guest.
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/solaris/plugin.rb
INFO manager: Registered plugin: Solaris guest.
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/solaris11/plugin.rb
INFO manager: Registered plugin: Solaris 11 guest.
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/suse/plugin.rb
INFO manager: Registered plugin: SUSE guest
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/tinycore/plugin.rb
INFO manager: Registered plugin: TinyCore Linux guest.
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/trisquel/plugin.rb
INFO manager: Registered plugin: Trisquel guest
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/ubuntu/plugin.rb
INFO manager: Registered plugin: Ubuntu guest
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/guests/windows/plugin.rb
INFO manager: Registered plugin: Windows guest.
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/hosts/alt/plugin.rb
INFO manager: Registered plugin: ALT Platform host
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/hosts/arch/plugin.rb
INFO manager: Registered plugin: Arch host
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/hosts/bsd/plugin.rb
INFO manager: Registered plugin: BSD host
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/hosts/darwin/plugin.rb
INFO manager: Registered plugin: Mac OS X host
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/hosts/freebsd/plugin.rb
INFO manager: Registered plugin: FreeBSD host
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/hosts/gentoo/plugin.rb
INFO manager: Registered plugin: Gentoo host
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/hosts/linux/plugin.rb
INFO manager: Registered plugin: Linux host
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/hosts/null/plugin.rb
INFO manager: Registered plugin: null host
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/hosts/redhat/plugin.rb
INFO manager: Registered plugin: Red Hat Enterprise Linux host
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/hosts/slackware/plugin.rb
INFO manager: Registered plugin: Slackware host
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/hosts/suse/plugin.rb
INFO manager: Registered plugin: SUSE host
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/hosts/windows/plugin.rb
INFO manager: Registered plugin: Windows host
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/kernel_v1/plugin.rb
INFO manager: Registered plugin: kernel
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/kernel_v2/plugin.rb
INFO manager: Registered plugin: kernel
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/providers/docker/plugin.rb
INFO manager: Registered plugin: docker-provider
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/providers/hyperv/plugin.rb
INFO manager: Registered plugin: Hyper-V provider
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/providers/virtualbox/plugin.rb
INFO manager: Registered plugin: VirtualBox provider
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/provisioners/ansible/plugin.rb
INFO manager: Registered plugin: ansible
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/provisioners/cfengine/plugin.rb
INFO manager: Registered plugin: CFEngine Provisioner
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/provisioners/chef/plugin.rb
INFO manager: Registered plugin: chef
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/provisioners/docker/plugin.rb
INFO manager: Registered plugin: docker
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/provisioners/file/plugin.rb
INFO manager: Registered plugin: file
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/provisioners/puppet/plugin.rb
INFO manager: Registered plugin: puppet
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/provisioners/salt/plugin.rb
INFO manager: Registered plugin: salt
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/provisioners/shell/plugin.rb
INFO manager: Registered plugin: shell
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/pushes/atlas/plugin.rb
INFO manager: Registered plugin: atlas
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/pushes/ftp/plugin.rb
INFO manager: Registered plugin: ftp
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/pushes/heroku/plugin.rb
INFO manager: Registered plugin: heroku
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/pushes/local-exec/plugin.rb
INFO manager: Registered plugin: local-exec
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/pushes/noop/plugin.rb
INFO manager: Registered plugin: noop
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/synced_folders/nfs/plugin.rb
INFO manager: Registered plugin: NFS synced folders
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/synced_folders/rsync/plugin.rb
INFO manager: Registered plugin: RSync synced folders
DEBUG global: Loading core plugin:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/synced_folders/smb/plugin.rb
INFO manager: Registered plugin: SMB synced folders
INFO vagrant: `vagrant` invoked: ["up"]
DEBUG vagrant: Creating Vagrant environment
INFO environment: Environment initialized
(#<Vagrant::Environment:0x0000000002af4d88>)
INFO environment: - cwd: /c/Users/lukas/salt-ssh-test
INFO environment: Home path: /c/Users/lukas/.vagrant.d
DEBUG environment: Effective local data path:
/c/Users/lukas/salt-ssh-test/.vagrant
INFO environment: Local data path: /c/Users/lukas/salt-ssh-test/.vagrant
DEBUG environment: Creating: /c/Users/lukas/salt-ssh-test/.vagrant
DEBUG manager: Enabling localized plugins
INFO manager: Plugins:
DEBUG bundler: Current generated plugin dependency list: []
DEBUG bundler: Generating new builtin set instance.
DEBUG bundler: Generating new plugin set instance. Skip gems - []
DEBUG bundler: Activating solution set: []
INFO manager: Loading plugins...
DEBUG manager: Enabling globalized plugins
INFO manager: Plugins:
DEBUG bundler: Current generated plugin dependency list: []
DEBUG bundler: Generating new builtin set instance.
DEBUG bundler: Generating new plugin set instance. Skip gems - []
DEBUG bundler: Activating solution set: []
INFO manager: Loading plugins...
INFO loader: Set :root =
["#<Pathname:/c/Users/lukas/salt-ssh-test/Vagrantfile>"]
DEBUG loader: Populating proc cache for
#<Pathname:/c/Users/lukas/salt-ssh-test/Vagrantfile>
DEBUG loader: Load procs for pathname:
/c/Users/lukas/salt-ssh-test/Vagrantfile
INFO loader: Loading configuration in order: [:home, :root]
DEBUG loader: Loading from: root (evaluating)
DEBUG loader: Configuration loaded successfully, finalizing and returning
DEBUG push: finalizing
INFO environment: Running hook: environment_plugins_loaded
INFO runner: Preparing hooks for middleware sequence...
INFO runner: 1 hooks defined.
INFO runner: Running action: environment_plugins_loaded
#<Vagrant::Action::Builder:0x0000000001bccbd0>
INFO environment: Running hook: environment_load
INFO runner: Preparing hooks for middleware sequence...
INFO runner: 1 hooks defined.
INFO runner: Running action: environment_load
#<Vagrant::Action::Builder:0x00000000030cd660>
DEBUG checkpoint_client: starting plugin check
INFO cli: CLI: [] "up" []
DEBUG cli: Invoking command class: VagrantPlugins::CommandUp::Command []
DEBUG checkpoint_client: waiting for checkpoint to complete...
DEBUG checkpoint_client: plugin check complete
DEBUG checkpoint_client: no information received from checkpoint
DEBUG command: 'Up' each target VM...
DEBUG command: Getting target VMs for command. Arguments:
DEBUG command: -- names: ["m1"]
DEBUG command: -- options: {:provider=>nil}
DEBUG command: Finding machine that match name: m1
INFO loader: Set "16486420_machine_m1" = ["[\"2\",
#<Proc:0x0000000002a4a9c8@/c/Users/lukas/salt-ssh-test/Vagrantfile:5>]"]
DEBUG loader: Populating proc cache for ["2",
#<Proc:0x0000000002a4a9c8@/c/Users/lukas/salt-ssh-test/Vagrantfile:5>]
INFO loader: Loading configuration in order: [:home, :root,
"16486420_machine_m1"]
DEBUG loader: Loading from: root (cache)
DEBUG loader: Loading from: 16486420_machine_m1 (evaluating)
DEBUG loader: Configuration loaded successfully, finalizing and returning
DEBUG push: finalizing
INFO base: VBoxManage path: VBoxManage
DEBUG environment: Initial usable provider list: []
DEBUG environment: Priority sorted usable provider list: []
DEBUG environment: Preferred provider list: []
INFO environment: Running hook: environment_unload
INFO host: Autodetecting host type for [#<Vagrant::Environment:
/c/Users/lukas/salt-ssh-test>]
DEBUG host: Trying: alt
DEBUG host: Trying: arch
DEBUG host: Trying: darwin
DEBUG host: Trying: freebsd
DEBUG host: Trying: gentoo
DEBUG host: Trying: redhat
DEBUG host: Trying: slackware
DEBUG host: Trying: suse
DEBUG host: Trying: bsd
DEBUG host: Trying: linux
INFO host: Detected: linux!
INFO runner: Preparing hooks for middleware sequence...
INFO runner: 1 hooks defined.
INFO runner: Running action: environment_unload
#<Vagrant::Action::Builder:0x00000000030c4b78>
ERROR vagrant: Vagrant experienced an error! Details:
ERROR vagrant: #<Vagrant::Errors::NoDefaultProvider: No usable default
provider could be found for your system.

Vagrant relies on interactions with 3rd party systems, known as
"providers", to provide Vagrant with resources to run development
environments. Examples are VirtualBox, VMware, Hyper-V.

The easiest solution to this message is to install VirtualBox, which
is available for free on all major platforms.

If you believe you already have a provider available, make sure it
is properly installed and configured. You can see more details about
why a particular provider isn't working by forcing usage with
`vagrant up --provider=PROVIDER`, which should give you a more specific
error message for that particular provider.>
ERROR vagrant: No usable default provider could be found for your system.

Vagrant relies on interactions with 3rd party systems, known as
"providers", to provide Vagrant with resources to run development
environments. Examples are VirtualBox, VMware, Hyper-V.

The easiest solution to this message is to install VirtualBox, which
is available for free on all major platforms.

If you believe you already have a provider available, make sure it
is properly installed and configured. You can see more details about
why a particular provider isn't working by forcing usage with
`vagrant up --provider=PROVIDER`, which should give you a more specific
error message for that particular provider.
ERROR vagrant:
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/lib/vagrant/environment.rb:438:in
`default_provider'
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/lib/vagrant/plugin/v2/command.rb:177:in
`block in with_target_vms'
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/lib/vagrant/plugin/v2/command.rb:204:in
`block in with_target_vms'
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/lib/vagrant/plugin/v2/command.rb:186:in
`each'
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/lib/vagrant/plugin/v2/command.rb:186:in
`with_target_vms'
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/plugins/commands/up/command.rb:87:in
`execute'
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/lib/vagrant/cli.rb:54:in
`execute'
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/lib/vagrant/environment.rb:291:in
`cli'
/opt/vagrant/embedded/gems/2.2.0/gems/vagrant-2.2.0/bin/vagrant:164:in
`<main>'
INFO interface: error: No usable default provider could be found for your
system.

Vagrant relies on interactions with 3rd party systems, known as
"providers", to provide Vagrant with resources to run development
environments. Examples are VirtualBox, VMware, Hyper-V.

The easiest solution to this message is to install VirtualBox, which
is available for free on all major platforms.

If you believe you already have a provider available, make sure it
is properly installed and configured. You can see more details about
why a particular provider isn't working by forcing usage with
`vagrant up --provider=PROVIDER`, which should give you a more specific
error message for that particular provider.
No usable default provider could be found for your system.

Vagrant relies on interactions with 3rd party systems, known as
"providers", to provide Vagrant with resources to run development
environments. Examples are VirtualBox, VMware, Hyper-V.

The easiest solution to this message is to install VirtualBox, which
is available for free on all major platforms.

If you believe you already have a provider available, make sure it
is properly installed and configured. You can see more details about
why a particular provider isn't working by forcing usage with
`vagrant up --provider=PROVIDER`, which should give you a more specific
error message for that particular provider.
INFO interface: Machine: error-exit ["Vagrant::Errors::NoDefaultProvider",
"No usable default provider could be found for your system.\n\nVagrant
relies on interactions with 3rd party systems, known as\n\"providers\", to
provide Vagrant with resources to run development\nenvironments. Examples
are VirtualBox, VMware, Hyper-V.\n\nThe easiest solution to this message is
to install VirtualBox, which\nis available for free on all major
platforms.\n\nIf you believe you already have a provider available, make
sure it\nis properly installed and configured. You can see more details
about\nwhy a particular provider isn't working by forcing usage
with\n`vagrant up --provider=PROVIDER`, which should give you a more
specific\nerror message for that particular provider."]
--
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 vagrant-up+***@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/d0e852f8-ac04-44e2-a308-78f5e34d2760%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Lukas
2018-10-18 12:54:26 UTC
Permalink
I found the issue in
https://github.com/hashicorp/vagrant/blob/67bb5d2e6c4ee4e6d9c36ee0c840544a79c265cc/lib/vagrant/util/platform.rb#L39

where it reads
# Use PATH values to check for `/mnt/c` path indicative of WSL
if ENV.fetch("PATH", "").downcase.include?("/mnt/c")

which is an incomplete check for WSL because the root can be changed via
/etc/wsl.conf to any arbitrary directory, not just /mnt/c (see
https://blogs.msdn.microsoft.com/commandline/2018/02/07/automatically-configuring-wsl/).

I've created a PR https://github.com/hashicorp/vagrant/pull/10313 to fix
this behaviour.
--
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 vagrant-up+***@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/vagrant-up/a3b457df-9514-463e-9f8f-baaaaaaf947a%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Loading...