From Fedora Project Wiki

(Create page)
 
m (grep missing from "verify the spice agent is running")
 
(11 intermediate revisions by 2 users not shown)
Line 2: Line 2:


|description=
|description=
Configure USB redirection for your guest, which allows streaming USB access to your VM, even if it's on a different host!
Test fancy spice features!


|setup=
|setup=
Initial test day setup (basically a function F18 VM). And a USB device to let your guest access.
Fedora 20+ host and Fedora 20+ guest. Older works but the defaults may not be in place.


|actions=
|actions=
# Shut off your guest. Open the hardware view in virt-manager
 
# Make sure the guest is configured with spice graphics and qxl video (this is the default if you chose 'Fedora 18' when installing)
=== Verify spice channel is configured correctly. ===
# Go to the 'Controller USB' page, change type to 'USB 2', click apply
 
# Go: Add Hardware->USB Redirection->Spice->Apply
* Start with a shutoff VM in virt-manager.
# Start the VM, but close virt-manager
* Verify the VM is using spice graphics.
# From the command line, as root, run: <br><pre>virt-viewer f18</pre>
* Verify the VM has a 'Channel spicevmc' attached.
# With virt-viewer, log into the guest so you have graphical desktop access
* Verify that 'Controller USB' has model 'USB 2'
# In virt-viewer, go to File->USB Redirection, and select your USB device
* Start the VM, log in to the desktop. Open a terminal and verify the spice agent is running: <pre>ps axwww | grep spice-vdagent</pre>
# Verify the device shows up in the guest and is usable
 
# In virt-viewer, go to File->USB Redirection, and unselect your device
=== USB redirection ===
# Verify the device is once again usable on the host
This streams your USB device access over a spice channel, allowing you to attach a local USB device to any VM, even one on a remote machine! And it seamlessly works even for Windows, and doesn't require any particular agent running in the VM. Yes, it's magic :)
 
* Start with a shutoff VM in virt-manager. Unplug the desired USB device from your host machine.
* Verify the VM had 'USB Redirection' listed on the hardware details page
* Start the VM. Log in to the desktop.
* With the VM console window focused, plug the USB device into your host machine. It should be automatically attached to your VM, and you will be notified in the VM as it sees the device attached (like a 'show files' notification for a thumb drive)
* Verify the device appears operational in the VM.
* From the virt-manager window, navigate to 'Virtual Machine->Redirect USB Device'
* See that your device is selected. Unselect it. It should revert to host access.
 
=== Automatic resolution change to match window size ===
 
{{admon/note | Growing resolution works with F22, but not shrinking resolution | See bug 1212201 }}
 
* Continuing from above with a running and logged in VM.
* Connect to the VM graphical console with virt-manager.
* Select View->Scale Display->Auto resize VM with window.
* Once selected, resize the viewer window: after a moment, the guest should automatically resize its resolution to fit the window.
* Try it a few more times, it should continue to work.
 
=== Host copy/paste ===
 
* Continuing from above with a running and logged in VM.
* Verify you can copy/paste text selection back and forth between the host and the guest.
 
=== Host to guest drag and drop file transfer ===
 
{{admon/note | Copy only works from host to guest | .}}
 
* Continuing from above with a running and logged in VM.
* On the host, open a file manager like 'nautilus'. Navigate to an existing file.
* Drag the file onto the VM console window.
* Verify the file is transfered to ~/Downloads at the destination. A nautilus window should open in the guest showing the Downloads folder.


|results=
|results=
No obvious errors occur, USB device is accessible like normal.
No obvious errors occur.
}}
}}


[[Category:Virtualization Test Cases]]
[[Category:Virtualization Test Cases]]

Latest revision as of 13:58, 26 August 2015

Description

Test fancy spice features!

Setup

Fedora 20+ host and Fedora 20+ guest. Older works but the defaults may not be in place.

How to test

Verify spice channel is configured correctly.

  • Start with a shutoff VM in virt-manager.
  • Verify the VM is using spice graphics.
  • Verify the VM has a 'Channel spicevmc' attached.
  • Verify that 'Controller USB' has model 'USB 2'
  • Start the VM, log in to the desktop. Open a terminal and verify the spice agent is running:
    ps axwww | grep spice-vdagent

USB redirection

This streams your USB device access over a spice channel, allowing you to attach a local USB device to any VM, even one on a remote machine! And it seamlessly works even for Windows, and doesn't require any particular agent running in the VM. Yes, it's magic :)

  • Start with a shutoff VM in virt-manager. Unplug the desired USB device from your host machine.
  • Verify the VM had 'USB Redirection' listed on the hardware details page
  • Start the VM. Log in to the desktop.
  • With the VM console window focused, plug the USB device into your host machine. It should be automatically attached to your VM, and you will be notified in the VM as it sees the device attached (like a 'show files' notification for a thumb drive)
  • Verify the device appears operational in the VM.
  • From the virt-manager window, navigate to 'Virtual Machine->Redirect USB Device'
  • See that your device is selected. Unselect it. It should revert to host access.

Automatic resolution change to match window size

Growing resolution works with F22, but not shrinking resolution
See bug 1212201
  • Continuing from above with a running and logged in VM.
  • Connect to the VM graphical console with virt-manager.
  • Select View->Scale Display->Auto resize VM with window.
  • Once selected, resize the viewer window: after a moment, the guest should automatically resize its resolution to fit the window.
  • Try it a few more times, it should continue to work.

Host copy/paste

  • Continuing from above with a running and logged in VM.
  • Verify you can copy/paste text selection back and forth between the host and the guest.

Host to guest drag and drop file transfer

Copy only works from host to guest
.
  • Continuing from above with a running and logged in VM.
  • On the host, open a file manager like 'nautilus'. Navigate to an existing file.
  • Drag the file onto the VM console window.
  • Verify the file is transfered to ~/Downloads at the destination. A nautilus window should open in the guest showing the Downloads folder.

Expected Results

No obvious errors occur.