Run exe on windows virtual machine from osx terminal - macos

I have installed a command line executable on a windows virtual machine on my mac. I would like to launch this exe from osx terminal. Is that possible ?

VMWare Fusion comes with CLI vmrun, which, however is not placed in the PATH by default.
'/Applications/VMware Fusion.app/Contents/Library/vmrun' -h
will tell you that there's a runProgramInGuest subcommand for running commands inside a given VM.

Related

Could not run "bash build/build.sh" command in Windows PowerShell

Currently I'm working on testing a github repository and I'm following the github's README.md that requires me to run "bash build/build.sh" command line to build environment. But I somehow could not make the command run in my PowerShell. Windows PowerShell keeps showing "Windows Subsystem for Linux has no installed distributions.
Use 'wsl.exe --list --online' to list available distributions
and 'wsl.exe --install ' to install.
Distributions can also be installed by visiting the Microsoft Store:
https://aka.ms/wslstore
Error code: Bash/Service/CreateInstance/GetDefaultDistro/WSL_E_DEFAULT_DISTRO_NOT_FOUND"
I have installed the Windows Subsystem for Linux Preview from Microsoft Store but I still could not run the "bash build/build.sh" command.
Question solved. I have solve it by following this youtube video.
https://youtu.be/mDmpnkjETpw
Basically you have to check two boxes in the "Turn Windows features on or off" before start trying out the Linux command.
Virtual Machine Platform
Windows Subsystem for Linux
Thanks for viewing.

Loading Driver in QEMU Running Windows on Windows

I want to run Windows 10 on Windows 10 with QEMU (not with other software). I downloaded QEMU, and set up environment variable. I also got the Windows 10 iso file, renamed it to win10.iso, and put that in the same directory as the QEMU folder. Then I ran this command in the QEMU folder with cmd prompt: qemu-system-x86_64.exe -boot d -cdrom win10.iso -m 2048
It worked fine, but when it asked for the drive, I got confused. image.
I clicked on the first option, and it said this. So clicked on the second option, and it gave me this. I clicked "load driver" and it gave me this. How do I make a device driver?
You misunderstood windows installer. The window on the first image asks you for installation type - installing a new version or upgrading an existing. The upgrade option is only available when you have an installed version and runs the installer from a booted windows, not when booting from installation media. So installing a new version is your choice. The window on third image says windows installer cant find any disks where it can install the OS. This is because you ran qemu with a cdrom and no disks. The solution here is not to load a driver, but run qemu with a hard disk.
First create a disk, for example so:
qemu-img.exe create -f qcow2 win10.qcow2 50G
Then run qemu with this disk:
qemu-system-x86_64.exe -boot d -cdrom win10.iso -m 2048 win10.qcow2

I have generated core-image-minimal on my linux and have installed qemu in windows, how do i run that in windows qemu?

I have generated core-image-minimal on linux, i want to run that on windows qemu.[core-image-minimal files], what is the command to run the image?(in linux i used the command "runqemu core-image-minimal")

How to initialize and run Docker on windows?

I have Docker installed on Windows 7 platform. However when I try to run boot2docker start, the console gives me:
Failed to get machine 'boot2docker-vm': machine does not exist.
Ok, so I try to initialize the machine: boot2docker init. What now happens is even though I have the ISO image on the same path as docker, it tries to download a new image (and then fails to do so).
I uninstalled both OracleVM and GIT before installing them with boot2docker bundle as advised on Docker forums, but now I don't know how to proceed.
I had the same problem on a Windows 7 64 bit system when I installed the entire boot2docker package. It seems that running the solely 64-bit based boot2docker image from a 32-bit OS image (e.g. created by Virtualbox) does not work.
The solution for me was
to activate Intel Virtualisation Technolologies in my BIOS
(Lenovo X61 for me). Note that the settings can be found either
under CPU or Security.
choose a 64 bit OS version in VirtualBox and boot in with the
image obtained by boot2docker.
In case you're trying to do this now
For Windows 10 64-bit: Pro, Enterprise, or Education (Build 15063 or later), follow the instructions to install Docker Desktop here https://docs.docker.com/docker-for-windows/install/.
If you have Windows systems that do not meet the requirements of Docker Desktop for Windows(in my case Microsoft Windows 10 Home Single Language), you can install Docker Toolbox by following the instructions here https://docs.docker.com/toolbox/toolbox_install_windows/.
boot2docker does not support sharing directories on Windows IIRC. The way I run Docker on windows is:
install VirtualBox
install Vagrant
create a directory (let's say c:\vm\docker)
download this Vagrantfile and save it under c:\vm\docker\Vagrantfile
open a DOS command prompt
go to the directory cd c:\vm\docker
start the VM vagrant up and wait for it to install, start up and get provisionned
connect to the VM vagrant ssh
play with docker docker images, etc
Also you might want a real console instead of using the DOS command prompt:
install Git Bash for Windows
install Console
setup Console to use Git Bash (see this guide)
use Console to run the vagrant up and vagrant ssh commands

Starting a Windows app from a Mac app in Parallels or VMWare

Given:
Mac with either Parallels or VMWare
A virtual machine with Windows installed.
A Windows GUI application Foo.exe installed in that Windows virtual machine.
A Mac application Bar.app
I'd like to start Foo.exe from Bar.app.
What are reasonable approaches to do this for Parallels?
How about VMWare?
Note: I've tried using Parallel's "prlctl exec" command, which can run a command on the VM's OS -- but I have not managed to make it launch a GUI application on the VM's display.
One way is:
You can register/associate file types in MAC OS X to exes in VMWare. So by programmatically launching an associated data file in the Finder it would launch the appropriate VMWare WindowsApp's exe.

Resources