(How to) Use Virt Manager from a portable USB HDD

Glenn

Administrator
Staff member
I have a USB I am planning on putting all my Virtual Machines on so I can take the USB with me to other PC's, In Linux Virtual Machine Manager requires the user have full access to the HDD images and even the install ISO's, to get around this I found you can run it as sudo and it works fine, else it's a pain in the butt!

Start_VM.sh
Code:
#!/bin/bash

pkexec env DISPLAY=$DISPLAY XAUTHORITY=$XAUTHORITY virt-manager

This script is in the root of the drive with sub folders;
/VMs
/ISOs

The script uses pkexec which is pretty much UAC - when you type your password it will open virt-manager with all the permissions it needs. including setting the display and the authorities it needs. You can then create VM's and add those folders into the Pools (as they call them), it works great and I figures some of you may wish to move your VM's off your home partition - as you can see in my latest video I have most of mine filled with VM's and they get quite large once you start taking snapshots etc.
 
Back
Top