QA:Testcase Virtualization Guest Suspend Hibernate

From FedoraProject

(Difference between revisions)
Jump to: navigation, search
(Add known bugs)
Line 32: Line 32:
  
 
# Start a VM, connect to the graphical console with virt-manager
 
# Start a VM, connect to the graphical console with virt-manager
# From the host machine, as root, suspend the guest with virsh: <br><pre># virsh dompmsuspend --target mem</pre>
+
# From the host machine, as root, suspend the guest with virsh: <br><pre># virsh dompmsuspend f18 --target mem</pre>
 
# Watch virsh until the VM is listed as 'suspended': <br><pre># virsh list --all</pre>
 
# Watch virsh until the VM is listed as 'suspended': <br><pre># virsh list --all</pre>
# Wake the guest up with virsh: <br><pre># virsh dompmwakeup</pre>
+
# Wake the guest up with virsh: <br><pre># virsh dompmwakeup f18</pre>
 
# Using the graphical console, verify the guest appeared to resume correctly
 
# Using the graphical console, verify the guest appeared to resume correctly
# From the host machine, as root, hibernate the guest with virsh: <br><pre># virsh dompmsuspend --target disk</pre>
+
# From the host machine, as root, hibernate the guest with virsh: <br><pre># virsh dompmsuspend f18 --target disk</pre>
 
# Watch virsh until the VM is listed as shutoff: <br><pre># virsh list --all</pre>
 
# Watch virsh until the VM is listed as shutoff: <br><pre># virsh list --all</pre>
# Wake the guest up with virsh: <br><pre># virsh dompmwakeup</pre>
+
# Start the quest again
 
# Verify that the VM resumes right where it left off
 
# Verify that the VM resumes right where it left off
  

Revision as of 11:57, 1 November 2012

Contents

Description

Suspend and Hibernate a VM. Verify it resumes as expected. For more details, see:

http://fedoraproject.org/wiki/Features/Virt_Guest_Suspend_Hibernate

Setup

Nothing beyond the initial test day setup (basically a function F18 VM).

How to test

Initiating suspend/hibernate from inside the guest

There are a couple known bugs here:

  • virt-manager will backtrace trying to show guests in the 'suspended' state bug 871237
  • Closing a graphical window triggers a guest resume bug 871240


  1. Start a VM, connect to the graphical console with virt-manager
  2. From inside the guest, as root, run:
    # pm-suspend
  3. Verify the state changes to 'suspended' in the main virt-manager window
  4. Click inside the black VM guest console, and press any key on the keyboard
  5. Verify the VM resumes right where it left off.
  6. From inside the guest, as root, run:
    # pm-hibernate
  7. Verify the guest appears to shutdown in the main virt-manager window
  8. Start the guest again
  9. Verify that the VM resumes right where it left off


Initiating suspend/hibernate from the host

  1. Start a VM, connect to the graphical console with virt-manager
  2. From the host machine, as root, suspend the guest with virsh:
    # virsh dompmsuspend f18 --target mem
  3. Watch virsh until the VM is listed as 'suspended':
    # virsh list --all
  4. Wake the guest up with virsh:
    # virsh dompmwakeup f18
  5. Using the graphical console, verify the guest appeared to resume correctly
  6. From the host machine, as root, hibernate the guest with virsh:
    # virsh dompmsuspend f18 --target disk
  7. Watch virsh until the VM is listed as shutoff:
    # virsh list --all
  8. Start the quest again
  9. Verify that the VM resumes right where it left off

Expected Results

No obvious errors encountered, guests seem to be functioning as normal after resuming.