Vagrant & VMWare Fusion Communication Failure after Mac Monterey 12.5.1 Update - vagrant

I use Vagrant to boot, configure and run my development environment (see vagrant file detail below)
I am receiving the following error in vagrant following a Mac OS (Monterey 12.5.1) update overnight:
Vagrant encountered an unexpected communications error with the
Vagrant VMware Utility driver. Please try to run the command
again. If this error persists, please contact support#hashicorp.com
Does anyone know what could cause this specifically? I believe the Utility is driving the issue but I'm uncertain how to track it down and clearly identify the cause.
I'll try to lay out my setup as simply as possible using a Macbook Pro (M1 Core - Arm64) Running Monterey 12.5.1 and guidance from the following Vagrant and VMWare Tech Preview on Apple M1 Pro
Install Rosetta via:
/usr/sbin/softwareupdate --install-rosetta --agree-to-license
Vagrant 2.3.0 (also tried 2.2.18)
VMware Fusion Technology Preview 21H1 (for ARM)
Simlink Generate via:
ln -s /Applications/VMWare\ Fusion\ Tech\ Preview.app /Applications/VMWare\ Fusion.app
Vagrant VMWare Utility (https://releases.hashicorp.com/vagrant-vmware-utility/1.0.21/vagrant-vmware-utility_1.0.21_x86_64.dmg)
Utility installed with:
vagrant plugin install vagrant-vmware-desktop
This was all working well prior to the update using the following Vagrant file:
Vagrant.configure(2) do |config|
config.vbguest.auto_update = false
config.vbguest.no_remote = true
config.vm.box = "uwbbi/bionic-arm64"
config.vm.hostname = "mywebsite"
config.vm.network "private_network", ip: "192.168.56.7"
config.vm.network "forwarded_port", guest: 80, host: 8080
config.vm.network "forwarded_port", guest: 1080, host: 1080
config.vm.synced_folder ".", "/var/www/app-cake2", #, :mount_options => ["dmode=777", "fmode=766"]
id: "mywebsite",
group:'vagrant',
owner:'www-data',
umask: "755"
config.vm.provider "vmware_fusion" do |v, override|
v.memory = 512
end
I have uninstalled and reinstalled using these instructions (and a few variations) with no success as of the time of this post.
Any suggestions or recommendations are appreciated in advance.
I tried to be as complete as possible but if you see something I've omitted please comment and I'll add.
Thanks!

Related

How to use firefox ui in vagrant box

I'm new to Vagrant
I've installed vagrant and vagrant box for ubuntu/xenial64 on my ubuntu machine. (Ubuntu box on Ubuntu host OS)
Inside the vagrant box, I installed openjdk-8, firefox, jenkins.
How do I access the firefox browser UI which is installed in the Vagrant box so that I can have access jenkins server.
After entering into box using vagrant ssh, When I type firefox in vagrant box, it is saying
Error: GDK_BACKEND does not match available displays
Same thing's happening when I try sudo firefox
Here is my vagrantfile:
Vagrant.configure(2) do |config|
config.vm.box = "ubuntu/xenial64"
config.vm.network :private_network, ip: "192.168.68.8"
end
Vagrant starts VMs in headless mode per default. You can configure it to start with a display by adding this to your Vagrantfile:
config.vm.provider "virtualbox" do |vb|
vb.gui = true
end
Then restart the VM.
vagrant reload

Vagrant unable to mount shared folders - No such file or directory

I have this Vagrantfile
Vagrant.configure(2) do |config|
config.vm.box = "ubuntu/trusty32"
config.vm.hostname = "app.local"
config.vm.network :private_network, ip: "192.168.20.20"
config.vm.synced_folder ".", "/vagrant", :mount_options => ['dmode=774','fmode=775']
config.vm.provider :virtualbox do |vb|
vb.name = "MyBox"
vb.memory = 512
vb.cpus = 2
end
config.vm.provision :shell, path: "install.sh"
end
that I used so far without problems (on Ubuntu and Windows). On Windows 10, I have upgraded both Oracle VM Virtual Box (5.1.16) and Vagrant (1.9.2) and now I get this error when trying to install the box:
Vagrant was unable to mount VirtualBox shared folders. This is usually
because the filesystem "vboxsf" is not available. This filesystem is
made available via the VirtualBox Guest Additions and kernel module.
Please verify that these guest additions are properly installed in the
guest. This is not a bug in Vagrant and is usually caused by a faulty
Vagrant box. For context, the command attempted was:
mount -t vboxsf -o dmode=774,fmode=775,uid=1000,gid=1000 vagrant /vagrant
The error output from the command was:
: No such file or directory
I also see this:
GuestAdditions versions on your host (5.1.16) and guest (4.3.36) do not match.
* Stopping VirtualBox Additions
and then it looks like the GuestAdditions is removed and the 5.1.16 version is installed, steps that ends with:
vboxadd.sh: Building Guest Additions kernel modules. vboxadd.sh:
Starting the VirtualBox Guest Additions.
Could not find the X.Org or XFree86 Window System, skipping.
After this, I still get:
Got different reports about installed GuestAdditions version:
Virtualbox on your host claims: 4.3.36 VBoxService inside the vm
claims: 5.1.16 Going on, assuming VBoxService is correct... Got
different reports about installed GuestAdditions version: Virtualbox
on your host claims: 4.3.36 VBoxService inside the vm claims:
5.1.16 Going on, assuming VBoxService is correct...
Is this a bug or am I doing something wrong?
It looks like this was fixed in 5.1.18. Updating to the latest version fixed the problem for me.
Change Log (Version 5.1.18):
Shared Folders: fixed case insensitive filename access (5.1.16 regression; Windows guests only; bug #16549)
Shared Folders: fixed access to long pathes (5.1.16 regression; Windows guests only; bugs #14651, #16564)

Vagrant with VirtualBox on Windows10: "Rsync" could not be found on your PATH

I've used Vagrant for a while on a windows 7 system. Now I've a new PC with windows 10. I installed Oracle Virtual Box and Vagrant and I try to start a machine with the command vagrant up.
The Vagrantfile is the same file that I used on my windows 7 system.
This is the content of the Vagrantfile:
Vagrant.configure(2) do |config|
config.vm.box = "debian/jessie64"
config.vm.provider "virtualbox" do |v|
v.customize ["modifyvm", :id, "--memory", "768"]
end
config.vm.provision :shell, path: "bootstrap.sh"
config.vm.network :private_network, ip: "172.27.146.17"
config.vm.hostname = "www.delevensstijl.hst1.nl"
config.hostsupdater.aliases = ["www.thelifestylemethod.hst1.nl"]
end
The error I get: "rsync" could not be found on your PATH. Make sure that rsync is properly installed on your system and available on the PATH.
Why is Vagrant looking for rsync since I use Virtualbox?
How can I workaround this error?
I found in another forum that the local Vagrant directory is mounted as "/vagrant" via rsync. This is set in the box itself, you can check by opening
C:\Users\{your_username}\.vagrant.d\boxes\debian-VAGRANTSLASH-jessie64\8.2.2\virtualbox\Vagrantfile
and see the setting
config.vm.synced_folder \
".",
"/vagrant",
type: "rsync"
to get around this I added the following line in my local Vagrantfile
config.vm.synced_folder ".", "/vagrant", type: "virtualbox"
and the error was resolved
I have solved this issue as below when use cent/7 at Windows 7.
Check the box synced_folder at C:\Users[username]\.vagrant.d\boxes\centos-VAGRANTSLASH-7\1602.02\virtualbox\Vagrantfile
config.vm.synced_folder ".", "/home/vagrant/sync", type: "rsync"
Override the defition at project Vagrantfile for directory mapping.
config.vm.synced_folder ".", "/home/vagrant/sync", type: "virtualbox"
I imagine the box might be prepared at non Windows system, this case can be happened on many boxes, such as fedora/23-cloud-base.
Seems like a bug. You can report it here. But it seems that your bug has been already reported as the issue 6631.
Nevertheless you can try to add rsync to your PATH and check the result. You can do it in 2 ways:
Install Cygwin and then launch vagrant up from its Cygwin Terminal
Download & unpack cwRsync
First of all this is not a bug it is expected behavior on Windows because the rsync is absent on Windows.
If you faced with this problem and want to use the rsync as a mechanism to sync folders you should:
Download the Cygwin from https://mingw-w64.org/doku.php/download/cygwin
Install the Cygwin with rsync + openssh modules. It's important bacause they is basent on a Window (you may select packages to install during installation on the Select packages phase)
Add x:\cygwin\bin, where 'x' is the drive on which you have installed the cygwin distribution, to the SYSTEM PATH.
Reboot your PC (not need on Windows 10)
That's all.
Thank you for your attention and have a nice day :-)
Using Vagrant/VirtualBox (5.06) on Windows7 with centos/7 box from Atlas: could not find rsync on the path. So, I installed via cygwin as suggested (had other stuff to install as well, including openssh). No joy. Tried changing the shared folder config to "virtualbox" rather than "rsync". No joy. Oh, forgot to check if the VirtualBox guest additions were in the box: they were not. Rsync worked bettter, but still chocked at the end (could not chdir to the source directory of the shared folder). However, the "type: virtualbox" config did work!
So the datapoint is: centos/7 with guest additions added and shared folder type set to "virtualbox" (overriding the box setting) on windows 7 works.
Worked out of the box (no changes, no guest additions) on MacOS.
I was facing same issue on Windows 10. Removing the below line helped me to fix the issue
Directory: C:\Users\xxxxxxxxxxxxx.vagrant.d\boxes\manageiq-VAGRANTSLASH-euwe\5.1.0\virtualbox
File: VagrantFile
Line to remove: config.vm.synced_folder ".", "/home/vagrant/sync", type: "rsync"
Next Steps:
Save the file
Open cygwin terminal
Go to vagrant directory
Run "vagrant up"
I was able to fix this problen using another bos from
C:\Users{your_username}.vagrant.d\boxes\box\subfolder\virtualbox\Vagrantfile
And adding
# Load include vagrant file if it exists after the auto-generated
# so it can override any of the settings
include_vagrantfile = File.expand_path("../include/_Vagrantfile", __FILE__)
load include_vagrantfile if File.exist?(include_vagrantfile)
I've tried the advises above but it didn't help. I use Windows 7, vagrant 1.9.1
As vm box I use centos 7 without guest addition installed.
vm.box = "centos/7"
To resolve this issue change clean 'vm.box' to box with preinstalled guest addition, for example
vm.box = "geerlingguy/centos7"
And also make sure there is no vbguest plugin installed because another error appears
vagrant plugin list
vagrant plugin uninstall vagrant-vbguest

VirtualBox 5.0 cannot access any network with Ubuntu Mate 15.04 host

It's my first question I've asked here, but I've been a long time reader of Stack Overflow.
I use Vagrant with VirtualBox to handle the server configurations of the several projects I'm working on. I've used VirtualBox and Ubuntu Mate for the last few months without any problems. But I've changed my hard drive yesterday and I had to reinstall Ubuntu Mate 15.04.
I've installed the build-essential package, VirtualBox 5.0 from the x64 package found on VirtualBox's website and Vagrant from Vagrant's website. I've pulled my old VagrantFile from GIT and relaunched the machine. Vagrant pull the correct image, as expected, but once the VM is running in VirtualBox, Vagrant can't ssh into it.
I used VirtualBox's interface to get into the guest's shell, and found that I could not access any network. Even VirtualBox auto-update tool cannot connect to the internet. I get the message :
The network operation failed with the following error: Unknown reason
I've formated my computer several times using different versions/flavors of Ubuntu to no avail. I've also rolled back to previous versions of VirtualBox, but no luck either. I've manually installed a guest with VirtualBox and the network is not working either.
I've did several searches on Google and Stack Overflow for similar problems, but the closest matches were for Windows 10 issues. But neither the host or the guest is running Windows.
My computer/os configuration is the same as before yesterday, except for the drive change. I don't understand why it isn't working as before.
Here's my VagrantFile if it can help you :
# -*- mode: ruby -*-
# vi: set ft=ruby :
VAGRANTFILE_API_VERSION = "2"
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
config.vm.box = "ubuntu/trusty32"
config.vm.network "private_network", ip: "192.168.33.15"
config.vm.network "public_network", ip: "10.1.1.207", bridge: "p4p1"
config.ssh.forward_agent = true
config.vm.synced_folder "src/", "/var/www/project",
owner: "www-data", group: "www-data"
config.vm.provider :virtualbox do |vb|
vb.customize ["modifyvm", :id, "--memory", "512"]
end
config.vm.provision "shell", path: "bin/shellprovider.sh"
end
Any help or any hint would be greatly appreciated.
Regards,
Eric Lacasse

Vagrant - windows box waiting for machine to boot. This may take a few minutes

I am running vagrant on Ubuntu 14.04 and have problem with running windows box http://aka.ms/vagrant-xp-ie8 .
After sudo vagrant up, i constantly see
Waiting for machine to boot. This may take a few minutes...
I ran 'vagrant up --debug 2>log' , and it looks like
this
Vagrant.configure(2) do |config|
config.vm.box = "http://aka.ms/vagrant-xp-ie8"
config.winrm.username = 'IEuser'
config.winrm.password = 'Passw0rd!'
config.vm.communicator = "winrm"
config.vm.network "public_network"
config.vm.provider "virtualbox" do |vb|
vb.gui = true
end
end
Do you have idea how to fix this?
I've had similar issues when setting up Windows guest VMs. I was using the IE11/Win7 VM from http://modern.ie.
Installing the latest version of the VirtualBox guest additions resolved it for me under OSX. Under Windows, I also turned on hardware virtualization in my BIOS.

Resources