Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.

Bug 698490

Summary: [6.1] The options of virsh dump are not checked properly.
Product: Red Hat Enterprise Linux 6 Reporter: Mark Wu <dwu>
Component: libvirtAssignee: Jiri Denemark <jdenemar>
Status: CLOSED ERRATA QA Contact: Virtualization Bugs <virt-bugs>
Severity: medium Docs Contact:
Priority: medium    
Version: 6.1CC: dallan, dyuan, eblake, mzhan, yoyzhang
Target Milestone: rc   
Target Release: 6.2   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: libvirt-0.9.1-1.el6 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-12-06 11:05:58 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Patch to fix this problem none

Description Mark Wu 2011-04-21 01:23:27 UTC
Description of Problem:
The options of virsh dump are not checked properly.
--live and --crash is exclusive option, but virsh dump does not detect an error
when the two options are specified at a time.

Version-Release number of selected component:

Red Hat Enterprise Linux Version Number: RHEL6.1
Release Number: Snapshot2
Architecture: x86_64
Kernel Version: 2.6.32-128.el6
Related Package Version: libvirt-client-0.8.7-15.el6
Related Middleware / Application: None

Drivers or hardware or architecture dependency:
None.

How reproducible:
Always.

Step to Reproduce:
1. Start a domain by "virsh start".
2. Invoke "virsh dump" with two options against the domain started.
# virsh dump --live --crash domain dumpfile

Actual Results:
virsh dump does not detect an error.

Expected Results:
virsh dump detects an error and outputs error messages.

Comment 1 Mark Wu 2011-04-21 01:25:14 UTC
Created attachment 493674 [details]
Patch to fix this problem

Comment 3 Dave Allan 2011-04-21 14:30:13 UTC
(In reply to comment #1)
> Created attachment 493674 [details]
> Patch to fix this problem

Hi Mark,

Thank you for the patch.  Please submit it to the upstream list at libvir-list and post a link to the archive here so we can follow discussion progress.

Dave

Comment 8 Jiri Denemark 2011-05-11 10:23:43 UTC
Fixed upstream by v0.9.0-155-gd9b46a0:

commit d9b46a0d0462e41691d9b132338c0f2ae38c152d
Author: Mark Wu <dwu>
Date:   Fri Apr 22 11:45:33 2011 +0200

    Make crash and live flags mutually exclusive in virDomainCoreDump
    
    They don't make any sense when used together.

Comment 9 zhanghaiyan 2011-05-25 08:32:17 UTC
Verified pass with libvirt-0.9.1-1.el6.x86_64
1. # virsh start rhel61_x86_64
Domain rhel61_x86_64 started
2. # virsh dump rhel61_x86_64 --live --crash /tmp/rhel61_x86_64.dump
error: Failed to core dump domain rhel61_x86_64 to /tmp/rhel61_x86_64.dump
error: invalid argument in crash and live flags are mutually exclusive

Comment 11 Min Zhan 2011-07-18 07:14:32 UTC
Move to Verified according to Comment #9

Comment 12 errata-xmlrpc 2011-12-06 11:05:58 UTC
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/RHBA-2011-1513.html