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 893363 - Guest aborted after a 'migrate_cancel'
Summary: Guest aborted after a 'migrate_cancel'
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: qemu-kvm
Version: 7.0
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: rc
: ---
Assignee: Hai Huang
QA Contact: Virtualization Bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-01-09 08:22 UTC by Qunfang Zhang
Modified: 2014-06-18 03:20 UTC (History)
6 users (show)

Fixed In Version: QEMU 1.4
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-06-13 11:05:02 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
gdb log for the aborted issue after 'migrate_cancel' (44.03 KB, text/plain)
2013-01-09 08:24 UTC, Qunfang Zhang
no flags Details

Description Qunfang Zhang 2013-01-09 08:22:39 UTC
Description of problem:
This issue is found accompanied with bug 893350. Please check bug 893350 first. As the migration doesn't finish and only 4k ram are left so I used 'migrate_cancel' to cancel to migration process. But sometimes guest will aborted.  Open this separate issue to track the aborted issue.

Version-Release number of selected component (if applicable):
kernel-3.6.0-0.29.el7.x86_64
qemu-kvm-1.3.0-3.el7.x86_64

How reproducible:
Sometimes. (Hit twice after five time attempts)


Steps to Reproduce:
. Boot a guest on src host, and also boot it with listening mode (-incoming tcp:0:5800" on dst host.

2. Running a memory r/w generator inside guest:

#cat test.c

#include <stdlib.h>
main()
//example to generate dirty pages and delay migration for demo purposes:
{
    unsigned char *array;
    long int i,j,k;
    unsigned char c;
    long int loop=0;
    array=malloc(1024*1024*1024);
    while(1)
    {
        for(i=0;i<1024;i++)
 {
            c=0;
            for(j=0;j<1024;j++)
            {
                c++;
                for(k=0;k<1024;k++)
                {
                    array[i*1024*1024+j*1024+k]=c;
                }
            }
        }
        loop++;
    }
}

#gcc test.c -o test
#./test

3. On dst host:
(qemu) migrate_set_capability xbzrle on 

4. On source host:
(qemu) migrate_set_capability xbzrle on 
(qemu) migrate_cache_size 2G
(qemu) migrate -d tcp:$dst_host_ip:5800

5. When "(qemu)info migrate" shows only 4k ram are left and migration never finished. Cancel migration process.
(qemu) migrate_cancel
  
Actual results:
Guest aborted. (Please check the attachment for detail log.)

Expected results:
Guest works well, migration is cancelled.

Additional info:

Comment 1 Qunfang Zhang 2013-01-09 08:24:01 UTC
Created attachment 675303 [details]
gdb log for the aborted issue after 'migrate_cancel'

Comment 3 Orit Wasserman 2013-01-10 09:54:08 UTC
Fixed in qemu 1.4:
http://lists.gnu.org/archive/html/qemu-devel/2012-12/msg02939.html

Comment 8 mazhang 2014-01-21 07:34:18 UTC
Can not reproduce this bug after 10 times try.

Host:
RHEL-7.0-20130306.0
qemu-kvm-1.3.0-3.el7.x86_64
ipxe-roms-qemu-20130517-2.gitc4bce43.el7.noarch
qemu-img-1.3.0-3.el7.x86_64
qemu-kvm-tools-1.3.0-3.el7.x86_64
qemu-kvm-common-1.3.0-3.el7.x86_64
qemu-kvm-debuginfo-1.3.0-3.el7.x86_64
kernel-3.7.0-0.36.el7.x86_64

Will update to the latest qemu-kvm and kernel then test this bug.

Comment 9 mazhang 2014-01-26 09:08:22 UTC
(In reply to mazhang from comment #8)
> Can not reproduce this bug after 10 times try.
> 
> Host:
> RHEL-7.0-20130306.0
> qemu-kvm-1.3.0-3.el7.x86_64
> ipxe-roms-qemu-20130517-2.gitc4bce43.el7.noarch
> qemu-img-1.3.0-3.el7.x86_64
> qemu-kvm-tools-1.3.0-3.el7.x86_64
> qemu-kvm-common-1.3.0-3.el7.x86_64
> qemu-kvm-debuginfo-1.3.0-3.el7.x86_64
> kernel-3.7.0-0.36.el7.x86_64
> 
> Will update to the latest qemu-kvm and kernel then test this bug.

Confirm with qzhang my steps, then update qemu-kvm and kernel re-test this bug.

Host:
qemu-kvm-1.5.3-39.el7.x86_64
kernel-3.10.0-78.el7.x86_64

Guest:
kernel-3.10.0-64.el7.x86_64

Steps:
1. Start qemu-kvm :
/usr/libexec/qemu-kvm \
-M pc \
-cpu Nehalem \
-m 2G \
-smp 4,sockets=2,cores=2,threads=1,maxcpus=16 \
-enable-kvm \
-name rhel7-64 \
-uuid 990ea161-6b67-47b2-b803-19fb01d30d12 \
-smbios type=1,manufacturer='Red Hat',product='RHEV Hypervisor',version=el6,serial=koTUXQrb,uuid=feebc8fd-f8b0-4e75-abc3-e63fcdb67170 \
-k en-us \
-rtc base=localtime,clock=host,driftfix=slew \
-nodefaults \
-monitor stdio \
-qmp tcp:0:6666,server,nowait \
-boot menu=on \
-bios /usr/share/seabios/bios.bin \
-chardev socket,id=seabioslog,path=/tmp/seabios,server,nowait \
-device isa-debugcon,chardev=seabioslog,iobase=0x402 \
-monitor unix:/tmp/guest-sock,server,nowait \
-netdev tap,id=hostnet0,vhost=on \
-device virtio-net-pci,netdev=hostnet0,id=net0,mac=52:54:00:39:13:2c \
-device virtio-balloon-pci,id=balloon0 \
-chardev socket,id=qmp_id_qmpmonitor1,path=/tmp/monitor-qmp,server,nowait \
-mon chardev=qmp_id_qmpmonitor1,mode=control  \
-drive file=/home/rhel7-64.raw,if=none,id=drive-virtio-disk0,format=raw,cache=none,werror=stop,rerror=stop,aio=threads \
-device virtio-blk-pci,scsi=off,bus=pci.0,drive=drive-virtio-disk0,id=virtio-disk0,bootindex=1 \
-vga qxl \
-spice port=5900,disable-ticketing \

2. Run the application generate dirty pages.

3. Enablem xbzrle, and migrate guest.

Result:
Qemu-kvm works well,migration success, not found core dumped after try more then 10 times.

So this bug has been fixed.

Comment 12 Ludek Smid 2014-06-13 11:05:02 UTC
This request was resolved in Red Hat Enterprise Linux 7.0.

Contact your manager or support representative in case you have further questions about the request.


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