Bug 916061

Summary: Dump progress only show up when memory-only dump finish
Product: Red Hat Enterprise Linux 7 Reporter: yanbing du <ydu>
Component: libvirtAssignee: John Ferlan <jferlan>
Status: CLOSED ERRATA QA Contact: Meina Li <meili>
Severity: low Docs Contact:
Priority: low    
Version: 7.1CC: cwei, dyuan, fj-lsoft-rh-dump, juzhang, lmen, michen, mzhan, xuzhang, yafu
Target Milestone: rc   
Target Release: 7.1   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: libvirt-4.3.0-1.el7 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
: 1193826 (view as bug list) Environment:
Last Closed: 2018-10-30 09:49:43 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 1193826    
Bug Blocks: 1630404    

Description yanbing du 2013-02-27 07:07:19 UTC
Description of problem:
Virsh dump --verbose option can display the progress of dump, but if do memory-only dump, the progress of dump will only show up when dump finish(100%). 

Version-Release number of selected component (if applicable):
libvirt-0.10.2-18.el6.x86_64 

How reproducible:
100%

Steps to Reproduce:
1.
# virsh dump vm1 /tmp/vm1.core --verbose
Dump: [ 40 %]
Dump: [ 67 %]
Dump: [ 78 %]
Dump: [ 91 %]
Dump: [100 %]
Domain vm1 dumped to /tmp/vm1.core

#virsh dump vm1 /tmp/vm1.core --memory-only --verbose

Dump: [100 %]
Domain vm1 dumped to /tmp/vm1.core 
2.
3.
  
Actual results:
Dump progress only show up when memory-only dump finish. 

Expected results:
Dump progress will display in time during memory-only dump. 

Additional info:

Comment 4 John Ferlan 2016-06-22 14:58:34 UTC
Move to consideration for 7.4

Comment 5 John Ferlan 2017-11-17 23:19:43 UTC
Patches have been posted upstream:

https://www.redhat.com/archives/libvir-list/2017-November/msg00731.html

Comment 7 John Ferlan 2018-02-06 13:07:33 UTC
After a few review rounds, the most recent set of upstream patches:

https://www.redhat.com/archives/libvir-list/2018-February/msg00171.html

to support memory-only dump have been pushed.

commit 150930e30986594c75d2d078daa58844f570c973
Author: John Ferlan <jferlan>
Date:   Mon Nov 20 15:40:30 2017 -0500

    qemu: Allow showing the dump progress for memory only dump
    
...
    
    If the QEMU version running is new enough (based on the DUMP_COMPLETED
    event), then we can add a 'detach' boolean to the dump-guest-memory
    command in order to tell QEMU to run in a thread. This ensures that we
    don't lock out other commands while the potentially long running dump
    memory is completed.
    
    This allows the usage of a qemuDumpWaitForCompletion which will wait
    for the event while the qemuDomainGetJobInfoDumpStats can be used via
    qemuDomainGetJobInfo in order to query QEMU to determine how far along
    the job is.
    
    Now that we have a true async job, we'll only set the dump_memory_only
    flag only when @detach=false; otherwise, we note that the job is a
    for stats dump this allows the opposite end for job info to determine
    what to copy.


$ git describe 150930e30986594c75d2d078daa58844f570c973
v4.0.0-173-g150930e30
$

Comment 9 Meina Li 2018-07-12 07:57:57 UTC
Verified on libvirt-4.5.0-2.el7.x86_64

Verified steps:

Do memory-only dump with --verbose.
# virsh dump rhel7 /tmp/rhel7.core --memory-only --verbose
Dump: [ 32 %]
Dump: [ 51 %]
Dump: [ 82 %]
Dump: [ 93 %]
Dump: [100 %]
Domain rhel7 dumped to /tmp/rhel7.core

# virsh domjobinfo rhel7
Job type:         Unbounded   
Operation:        Dump        
Time elapsed:     14796        ms
Memory processed: 2.111 GiB
Memory remaining: 14.074 MiB
Memory total:     2.125 GiB

Comment 11 errata-xmlrpc 2018-10-30 09:49:43 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.

https://access.redhat.com/errata/RHSA-2018:3113

Comment 12 John Ferlan 2019-02-15 11:50:48 UTC
*** Bug 1658004 has been marked as a duplicate of this bug. ***