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 1002012 - QMP BLOCK_IO_ERROR event after offline migration from scsi=on to scsi=off
Summary: QMP BLOCK_IO_ERROR event after offline migration from scsi=on to scsi=off
Keywords:
Status: CLOSED WORKSFORME
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: qemu-kvm
Version: 7.0
Hardware: x86_64
OS: Linux
high
high
Target Milestone: rc
: ---
Assignee: Paolo Bonzini
QA Contact: Virtualization Bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-08-28 10:39 UTC by Jun Li
Modified: 2014-06-17 14:51 UTC (History)
9 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2014-06-17 14:51:29 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Jun Li 2013-08-28 10:39:45 UTC
Description of problem:
On src host, do migration with scsi=on. After migration boot guest with scsi=off on dst host, QMP will print BLOCK_IO_ERROR event. At the same time, can not use mouse inside guest.

Version-Release number of selected component (if applicable):
win8-64
qemu-kvm-1.5.2-4.el7.x86_64

How reproducible:
100%

Steps to Reproduce:
1.On src host, boot guest with scsi=off and do migration.
# /usr/libexec/qemu-kvm -M pc -cpu SandyBridge -enable-kvm -m 4G -smp 4,sockets=2,cores=2,threads=1 -name juli -uuid 355a2475-4e03-4cdd-bf7b-5d6a59edaa61 -rtc base=localtime,clock=host,driftfix=slew -drive file=/home/win8-64.raw,if=none,cache=none,aio=native,format=raw,id=drive0 -device virtio-blk-pci,bus=pci.0,drive=drive0,scsi=on,bootindex=0 -netdev tap,id=hostnet0,vhost=off,script=/etc/qemu-ifup -device virtio-net-pci,netdev=hostnet0,id=virtio-net-pci0,mac=24:be:05:14:0d:52,bootindex=1 -k en-us -boot menu=on -qmp tcp:0:4445,server,nowait -vnc :1 -monitor stdio

(QMP)  { "execute": "stop"}
(qemu)  migrate "exec:cat > saved_image_win8_64"
(QMP)  {"execute": "query-migrate"}
                Migration status: completed
(QMP) {"execute": "quit"}

2.On dst host, boot guest with scsi=off.
# /usr/libexec/qemu-kvm -M pc -cpu SandyBridge -enable-kvm -m 4G -smp 4,sockets=2,cores=2,threads=1 -name juli -uuid 355a2475-4e03-4cdd-bf7b-5d6a59edaa61 -rtc base=localtime,clock=host,driftfix=slew -drive file=/root/saved_image_win8_64,if=none,cache=none,aio=native,format=raw,id=drive0 -device virtio-blk-pci,bus=pci.0,drive=drive0,scsi=off,config-wce=off,bootindex=0 -netdev tap,id=hostnet0,vhost=off,script=/etc/qemu-ifup -device virtio-net-pci,netdev=hostnet0,id=virtio-net-pci0,mac=24:be:05:14:0d:52,bootindex=1 -k en-us -boot menu=on -qmp tcp:0:4445,server,nowait -vnc :1 -monitor stdio  -incoming "exec:cat saved_image_win8_64"

3. Check the mouse in guest and output of QMP. 

Actual results:
Can not use mouse inside guest.
QMP outputs:
{"timestamp": {"seconds": 1377679844, "microseconds": 390919}, "event": "BLOCK_IO_ERROR", "data": {"device": "drive0", "operation": "read", "action": "report"}}
{"timestamp": {"seconds": 1377679844, "microseconds": 391251}, "event": "BLOCK_IO_ERROR", "data": {"device": "drive0", "operation": "read", "action": "report"}}
{"timestamp": {"seconds": 1377679844, "microseconds": 391615}, "event": "BLOCK_IO_ERROR", "data": {"device": "drive0", "operation": "read", "action": "report"}}
{"timestamp": {"seconds": 1377679844, "microseconds": 391994}, "event": "BLOCK_IO_ERROR", "data": {"device": "drive0", "operation": "read", "action": "report"}}
{"timestamp": {"seconds": 1377679844, "microseconds": 640932}, "event": "BLOCK_IO_ERROR", "data": {"device": "drive0", "operation": "read", "action": "report"}}
{"timestamp": {"seconds": 1377679844, "microseconds": 765953}, "event": "BLOCK_IO_ERROR", "data": {"device": "drive0", "operation": "read", "action": "report"}}
{"timestamp": {"seconds": 1377679844, "microseconds": 766330}, "event": "BLOCK_IO_ERROR", "data": {"device": "drive0", "operation": "read", "action": "report"}}
{"timestamp": {"seconds": 1377679844, "microseconds": 766689}, "event": "BLOCK_IO_ERROR", "data": {"device": "drive0", "operation": "read", "action": "report"}}
{"timestamp": {"seconds": 1377679844, "microseconds": 767059}, "event": "BLOCK_IO_ERROR", "data": {"device": "drive0", "operation": "read", "action": "report"}}
{"timestamp": {"seconds": 1377679844, "microseconds": 767401}, "event": "BLOCK_IO_ERROR", "data": {"device": "drive0", "operation": "read", "action": "report"}}
{"timestamp": {"seconds": 1377679844, "microseconds": 767743}, "event": "BLOCK_IO_ERROR", "data": {"device": "drive0", "operation": "read", "action": "report"}}
{"timestamp": {"seconds": 1377679844, "microseconds": 768068}, "event": "BLOCK_IO_ERROR", "data": {"device": "drive0", "operation": "read", "action": "report"}}
{"timestamp": {"seconds": 1377679844, "microseconds": 768280}, "event": "BLOCK_IO_ERROR", "data": {"device": "drive0", "operation": "read", "action": "report"}}
{"timestamp": {"seconds": 1377679844, "microseconds": 859688}, "event": "BLOCK_IO_ERROR", "data": {"device": "drive0", "operation": "read", "action": "report"}}
{"timestamp": {"seconds": 1377679844, "microseconds": 860114}, "event": "BLOCK_IO_ERROR", "data": {"device": "drive0", "operation": "read", "action": "report"}}
{"timestamp": {"seconds": 1377679844, "microseconds": 953413}, "event": "BLOCK_IO_ERROR", "data": {"device": "drive0", "operation": "write", "action": "report"}}
{"timestamp": {"seconds": 1377679844, "microseconds": 984663}, "event": "BLOCK_IO_ERROR", "data": {"device": "drive0", "operation": "read", "action": "report"}}
{"timestamp": {"seconds": 1377679844, "microseconds": 984959}, "event": "BLOCK_IO_ERROR", "data": {"device": "drive0", "operation": "read", "action": "report"}}
: "report"}}
........


Expected results:
The mouse can use as normal inside guest.
qmp output as normal.

Additional info:
For rhel7 guest. qemu-kvm quit directly when booting guest with commmand line above.  I amn't sure if it is a new issue.  Do I need to file a new bug to track it for RHEL7 guest.


QEMU 1.5.2 monitor - type 'help' for more information
(qemu) qemu-kvm: Features 0x30000ed4 unsupported. All
qemu: warning: error while loading state for instance 0x0 of device '0000:00:03.0/virtio-blk'
load of migration failed

Comment 3 Ademar Reis 2014-06-16 21:56:00 UTC
Let me try to clarify, since there's some contradiction in the bug description:

You're

 - Booting src with scsi=on
 - Booting dst with scsi=off
 - migrating from src to dst

Looks like a regression from 800536, fixed by Paolo back in 2012 on RHEL6 and upstream:

RHEL6:

commit 55e1449419ead75ba6cdd482a4f340bdaf41a73a
Author: Paolo Bonzini <pbonzini>
Date:   Tue Mar 13 15:39:10 2012 +0100

    force-enable VIRTIO_BLK_F_SCSI if present on migration source
[...]


Upstream:

commit a6c5c84ae25bc68f22725f77d6d77c98af5c4f9e
Author: Paolo Bonzini <pbonzini>
Date:   Wed May 16 12:54:06 2012 +0200

    virtio-blk: always enable VIRTIO_BLK_F_SCSI
[...]


Jun Li: Please validate my observation above and test it on RHEL6.6. Thanks.

Comment 4 Jun Li 2014-06-17 03:28:18 UTC
Retest this issue with following version of components:

2.6.32-477.el6.x86_64
qemu-kvm-0.12.1.2-2.427.el6.x86_64

Steps as comment #0, after step 3, all works well, no any error.

==================================
Also retest with rhel 7 host.

Components version:
qemu-kvm-rhev-1.5.3-60.el7ev_0.2.x86_64
3.10.0-123.el7.x86_64

cli:
src:
---
# /usr/libexec/qemu-kvm -M pc -cpu SandyBridge -enable-kvm -m 4G -smp 4,sockets=2,cores=2,threads=1 -name juli -uuid 355a2475-4e03-4cdd-bf7b-5d6a59edaa61 -rtc base=localtime,clock=host,driftfix=slew -drive file=/home/win8-64-virtio.raw,if=none,cache=none,aio=native,format=raw,id=drive0 -device virtio-blk-pci,bus=pci.0,drive=drive0,scsi=on,bootindex=0 -k en-us -boot menu=on -qmp tcp:0:4445,server,nowait -vnc :1 -monitor stdio
dst:
---
# /usr/libexec/qemu-kvm -M pc -cpu SandyBridge -enable-kvm -m 4G -smp 4,sockets=2,cores=2,threads=1 -name juli -uuid 355a2475-4e03-4cdd-bf7b-5d6a59edaa61 -rtc base=localtime,clock=host,driftfix=slew -drive file=/home/win8-64-virtio.raw,if=none,cache=none,aio=native,format=raw,id=drive0 -device virtio-blk-pci,bus=pci.0,drive=drive0,scsi=off,bootindex=0 -k en-us -boot menu=on -qmp tcp:0:4445,server,nowait -vnc :1 -monitor stdio -incoming "exec:cat saved_image_win8_64"

Steps as comment #0, after step 3, guest and qemu-kvm works, no any error. Can not reproduce this bz currently.


As above testing, any issue, free to update it in the bz. 


Best Regards,
Jun Li

Comment 5 Ademar Reis 2014-06-17 14:51:29 UTC
OK, closing then. Thanks for the update.


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