The easy way to run a virtual machine on LAN with Linux
Quickemu is a fantastic, easy-to-use tool that makes creating virtual machines on the Linux desktop a breeze. But did you know that you can run these virtual machines on the LAN? Here’s how!
Installing Quickemu on Linux
The easiest way to run a virtual machine over the LAN with Linux is by using Quickemu. This tool automates the configuration and setup of QEMU virtual machines on Linux and makes remote connections (with the Spice protocol) easier.
To install Quickemu, you’ll need to open up a terminal window. You can launch a terminal window by pressing Ctrl + Alt + T on the keyboard. Or, search for “Terminal” in the app menu and launch it that way.
With the terminal window open and ready to use, follow the installation instructions below that correspond with the Linux OS you use.
Ubuntu
On Ubuntu, Quickemu is installable via a PPA. Enter the add-apt-repository command to set up the PPA on your system.
sudo apt-add-repository ppa:flexiondotorg/quickemu
With the repo added to your system, run the apt update command. Then, install the software on Ubuntu using the apt install command.
sudo apt install quickemu
Debian
Sadly, the Quickemu PPA doesn’t work with Debian, even though they share a packaging format. Thankfully, you can install the software with the following git command.
git clone --depth=1 https://github.com/wimpysworld/quickemu
After cloning the software to your computer, run the cd command and enter the “quickemu” folder. You can then use Quickemu and Quickget with the following commands.
Note: you must install all dependencies listed on the Quickemu page for the app to work on Debian.
cd quickemu/
Run quickemu:
./quickemu
Run quickget:
./quickget
Arch Linux
The Quickemu app is available as an AUR package in the Arch Linux User Repository. To install Quickemu on your system, you’ll need to install the Trizen AUR helper. You can set up Trizen with the commands below.
sudo pacman -S git base-devel
git clone https://aur.archlinux.org/trizen.git
cd trizen/
makepkg -sri
With the Trizen AUR helper installed on your system, you can install the Quickemu application using the trizen -S command.
trizen -S quickemu
Fedora/OpenSUSE
Fedora Linux and OpenSUSE Linux users do not have a packaged way to install the Quickemu app. Instead, you’ll have to download the software from Github and use it that way.
Note: you must install all dependencies listed on the Quickemu page to use Quickemu on Fedora
git clone --depth=1 https://github.com/wimpysworld/quickemu
Once you’ve downloaded the software to your computer, use the CD command to enter the “quickemu” folder.
cd quickemu/
Run quickemu:
./quickemu
Run quickget:
./quickget
Setting up a VM
Setting up a VM with Quickemu is very easy. In this guide, we’ll set up a Debian VM. However, there are a lot of VMs to choose from. To create a VM, follow the step-by-step instructions below.
Step 1: Run the quickget debian command. This command will print out available Debian VMs.
quickget debian
Step 2: After entering the command from Step 1, you’ll see “ERROR! You must specify a release.” Enter your release and preferred desktop. For example, you’d run the command below to set up a Debian 11 VM with Mate.
quickget debian 11.3.0 mate
Step 3: Once you specify your desktop and version, Quickemu will begin downloading and preparing your VM. When the process is complete, move to the next section of the guide.
Running the VM in Spice mode
You’ll need to run it in Spice mode to connect to the VM over LAN from any PC. To run your VM in spice mode, execute the following quickemu command. In this guide, we’ll run our Debian Mate VM.
sudo quickemu --vm debian-11.3.0-mate.conf --display spice
By running the VM in Spice mode, you can access it remotely on any LAN-connected computer via the spice://
protocol. By default, Spice runs on port 5930.
Installing remote Viewer
You’ll need a remote VM viewer installed on your Linux or Windows PC to access your VM over the LAN. Follow the installation instructions below to install the app.
Ubuntu
sudo apt install virt-viewer
Debian
sudo apt-get install virt-viewer
Arch Linux
sudo pacman -S virt-viewer
Fedora
sudo dnf install virt-viewer
OpenSUSE
sudo zypper install virt-viewer
Microsoft Windows
Remote Viewer is available for Microsoft Windows. Download the official MSI installer here.
Connecting to the VM over LAN
Open the Remote Viewer application on your Linux (or Windows) desktop. Next, enter spice://
into the connection bar.
spice://
After entering spice://, add in the host computer’s LAN IP address. For example, if the Linux PC hosting the VM’s LAN IP is: 10.218.1.83, you’d enter the following into Remote Viewer.
spice://10.218.1.83
Finally, you’ll need to add the port after specifying the IP address. By default, Quickemu should use port 5930. However, if this port doesn’t work, refer to the terminal to determine the port number.
spice://10.218.1.83:5930
AKA
spice://YOUR_VM_SERVER_OR_PC_IP:5930
With the IP and port specified, select the “Connect” button. When you click “Connect,” the Remote Viewer app will give you access to the Quickemu VM over LAN. Enjoy!