Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 810799 - virsh list and "--managed-save " flag can't list the domains with managed save state
virsh list and "--managed-save " flag can't list the domains with managed sav...
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: libvirt (Show other bugs)
6.3
Unspecified Linux
medium Severity medium
: rc
: ---
Assigned To: Peter Krempa
Virtualization Bugs
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2012-04-09 04:32 EDT by hongming
Modified: 2013-02-21 02:11 EST (History)
8 users (show)

See Also:
Fixed In Version: libvirt-0.9.13-3.el6
Doc Type: Bug Fix
Doc Text:
Feature bug fix.
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-02-21 02:11:40 EST
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2013:0276 normal SHIPPED_LIVE Moderate: libvirt security, bug fix, and enhancement update 2013-02-20 16:18:26 EST

  None (edit)
Description hongming 2012-04-09 04:32:51 EDT
Description of problem:
virsh list and "--managed-save " flag can't list the domains with managed save state.

Version-Release number of selected component (if applicable):
kernel-2.6.32-250.el6.x86_64
libvirt-0.9.10-10.el6.x86_64
qemu-kvm-0.12.1.2-2.270.el6.x86_64

How reproducible:
100%

Steps to Reproduce:
1. Managed save one domain
# virsh managedsave rhel6u32
Domain rhel6u32 state saved by libvirt

2. List domains with managed save state.
# virsh list --managed-save
Id Name             State
----------------------------------------------------
18 winxp-x86_64     running


3. # virsh list --managed-save --all
Id  Name             State
----------------------------------------------------
18 winxp-x86_64      running
- kvm-rhel3u9-i386   shut off
- rhel6u32           saved


  
Actual results:
virsh list and "--managed-save" flag can't list the domains with managed save state. It only list running domains. If use "--managed-save --all" flag , the domains with managed save states can be listed.

Expected results:
virsh list and "--managed-save " flag can list the domains with managed save state.

Additional info:
Comment 2 dyuan 2012-04-09 05:04:05 EDT
It's not very clear for the --managed-save option in "virsh help".

# virsh help list

--managed-save   mark domains with managed save state


# man virsh 

If --managed-save is specified, then domains that have managed save state (only possible if they are in the shut off state) will instead show as saved in the listing. This flag is usable only with the default --table output.

# virsh list --table --manged-save

only list the running domains.
Comment 3 Peter Krempa 2012-04-10 05:53:49 EDT
We could modify the semantics of the --managed-save flag, that would automaticaly imply listing inactive domains when it's specified or just document that you need to specify --all or --inactive to produce useful results.

What would be the preferred approach?
Comment 4 Daniel Berrange 2012-04-10 06:00:37 EDT
Just clarify the documentation IMHO
Comment 5 Peter Krempa 2012-04-10 09:57:09 EDT
Added documentation about the usage of --managed-save upstream:

commit cc5100654b2aff0933ab4aa447a71bfd7ddbf2bd
Author: Peter Krempa <pkrempa@redhat.com>
Date:   Tue Apr 10 12:21:03 2012 +0200

    virsh: Clarify use of the --managed-save flag for the list command
    
    The documentation for the flag doesn't clearly state that the flag only
    enhances the output and the user needs to specify other flags to list
    inactive domains, that are enhanced by this flag.
Comment 8 hongming 2012-07-25 03:23:10 EDT
Verify it using the following version.

libvirt-0.9.13-3.el6.x86_64


Steps

# man virsh 

 If --managed-save is specified, then domains that have managed
 save state (only possible if they are in the shut off state, so
 you need to specify --inactive or --all to actually list them)
 will instead show as saved in the listing. This flag is usable
 only with the default --table output.  Note that this flag does
 not filter the list of domains.


The result is expected. So move its status to VERIFIED.
Comment 9 errata-xmlrpc 2013-02-21 02:11:40 EST
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHSA-2013-0276.html

Note You need to log in before you can comment on or make changes to this bug.