Bug 847594 - [virtio-win][scsi]Cannot unplug scsi data disk from QMP on windows 7 32 guest
[virtio-win][scsi]Cannot unplug scsi data disk from QMP on windows 7 32 guest
Status: CLOSED CURRENTRELEASE
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: virtio-win (Show other bugs)
7.0
Unspecified Unspecified
medium Severity medium
: rc
: 7.0
Assigned To: Vadim Rozenfeld
Virtualization Bugs
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2012-08-13 01:21 EDT by Min Deng
Modified: 2014-11-09 05:44 EST (History)
14 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2014-11-09 05:44:44 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)
Error message (657.97 KB, image/png)
2012-08-13 01:21 EDT, Min Deng
no flags Details

  None (edit)
Description Min Deng 2012-08-13 01:21:59 EDT
Created attachment 603848 [details]
Error message

Description of problem:
unplug a virtio scsi disk failed as there was an error message.

Version-Release number of selected component (if applicable):
virtio-win-prewhql-0.1-32
How reproducible:
Always,
Steps to Reproduce:
1.boot up guest with the following CLI
  /usr/libexec/qemu-kvm -m 2G -smp 4 -cpu SandyBridge,+x2apic,family=0xf -usb -device usb-tablet -device virtio-scsi-pci,id=scsi0 -drive file=win7-32-scsi.qcow2,format=qcow2,if=none,id=drive-virtio0,cache=writeback,werror=stop,rerror=stop,serial=systemdisk -device scsi-hd,bus=scsi0.0,drive=drive-virtio0,id=virtio-blk-pci0,bootindex=1 -netdev tap,sndbuf=0,id=hostnet0,script=/etc/qemu-ifup,downscript=no -device e1000,netdev=hostnet0,mac=00:12:27:44:27:18 -uuid 57d734cb-bdf2-44d7-b750-9dff30e9d46b -no-kvm-pit-reinjection -chardev socket,id=111a,path=/tmp/monitor-win732-scsi,server,nowait -mon chardev=111a,mode=readline -rtc base=localtime,clock=host,driftfix=slew -chardev socket,id=seabios_debug,path=/tmp/monitor-seabios,server,nowait -device isa-debugcon,iobase=0x402,chardev=seabios_debug -device virtio-scsi-pci,id=scsi1 -drive file=disk1.qcow2,if=none,format=qcow2,cache=writeback,id=drive-virtio-data1,werror=stop,rerror=stop,serial=disk1data -device scsi-hd,bus=scsi1.0,id=virtio-data1,drive=drive-virtio-data1 -device virtio-scsi-pci,id=scsi2 -drive file=disk2.qcow2,if=none,cache=writeback,format=qcow2,id=drive-virtio-data2,werror=stop,rerror=stop -device scsi-hd,bus=scsi2.0,id=virtio-data2,drive=drive-virtio-data2 -device virtio-scsi-pci,id=scsi3 -drive file=disk3.qcow2,cache=writethrough,if=none,format=qcow2,id=drive-virtio-data3,werror=stop,rerror=stop -device scsi-hd,bus=scsi3.0,id=virtio-data3,drive=drive-virtio-data3 -device virtio-scsi-pci,id=scsi4 -drive file=disk4.qcow2,if=none,format=qcow2,cache=writeback,id=drive-virtio-data4,werror=stop,rerror=stop,readonly=on -device scsi-hd,bus=scsi4.0,id=virtio-data4,drive=drive-virtio-data4 -bios /usr/share/seabios/bios-pm.bin -spice port=5931,disable-ticketing -vga qxl -monitor stdio -qmp tcp:0:4444,server,nowait -device virtio-scsi-pci,id=scsiadd -drive file='/home/disk.qcow2',if=none,id=drive-scsi0-0-add,if=none,media=disk,cache=none,format=qcow2,werror=stop,aio=native -device scsi-hd,bus=scsiadd.0,drive=drive-scsi0-0-add,id=scsiaddd

2.telnet ip port 
  in QMP
{"execute":"qmp_capabilities"}
{"return": {}}
{"execute":"device_del","arguments":{"id":"scsiaddd"}}
{"return": {}}
{"execute":"device_del","arguments":{"id":"scsiadd"}}
{"return": {}}

3.Go back to guest and check the disk status,it should be removed successfully.
  
Actual results:
The disk cannot be removed from the guest and please refer to the screenshot for the error

Expected results:
It can be removed successfully without any errors 

Additional info:
Please use such a disk to reproduce the issue,which was ever formatted by the guest. And shutdown -> boot up again ...
Comment 8 Ronen Hod 2013-07-29 05:12:48 EDT
QE,
If it works from QEMU command line, then it is probably a QMP bug.
Comment 9 Vadim Rozenfeld 2014-01-03 16:51:56 EST
(In reply to Ronen Hod from comment #8)
> QE,
> If it works from QEMU command line, then it is probably a QMP bug.

I didn't have any problem deleting virtio-scsi device from the QEMU command line.
Comment 10 juzhang 2014-01-05 21:19:07 EST
Hi Mdeng,

Could you have a look comment9 and comment8 and add comment?

Best Regards,
Junyi
Comment 11 Mike Cao 2014-01-05 22:27:58 EST
(In reply to Vadim Rozenfeld from comment #9)
> (In reply to Ronen Hod from comment #8)
> > QE,
> > If it works from QEMU command line, then it is probably a QMP bug.
> 
> I didn't have any problem deleting virtio-scsi device from the QEMU command
> line.

Did you try to unplug it when the disk is in use ?
Comment 12 Min Deng 2014-01-06 00:49:09 EST
   QE tested the bug with the following CLI and build 74,still hit similar issue (both from qemu monitor and QMP).make sure the disk wasn't used while removing.
 /usr/libexec/qemu-kvm -m 2G -smp 4 -cpu SandyBridge,+x2apic,family=0xf -usb -device usb-tablet -device virtio-scsi-pci,id=scsi0 -drive file=win7-32.raw,format=raw,if=none,id=drive-virtio0,cache=writeback,werror=stop,rerror=stop,serial=systemdisk -device scsi-hd,bus=scsi0.0,drive=drive-virtio0,id=virtio-blk-pci0,bootindex=1 -netdev tap,sndbuf=0,id=hostnet0,script=/etc/qemu-ifup,downscript=no -device e1000,netdev=hostnet0,mac=00:12:27:44:27:18 -uuid 57d734cb-bdf2-44d7-b750-9dff30e9d46b -no-kvm-pit-reinjection -chardev socket,id=111a,path=/tmp/monitor-win732-scsi,server,nowait -mon chardev=111a,mode=readline -rtc base=localtime,clock=host,driftfix=slew -chardev socket,id=seabios_debug,path=/tmp/monitor-seabios,server,nowait -device isa-debugcon,iobase=0x402,chardev=seabios_debug -device virtio-scsi-pci,id=scsi1 -drive file=disk1.raw,if=none,format=raw,cache=writeback,id=drive-virtio-data1,werror=stop,rerror=stop,serial=disk1data -device scsi-hd,bus=scsi1.0,id=virtio-data1,drive=drive-virtio-data1 -device virtio-scsi-pci,id=scsi2 -drive file=disk2.raw,if=none,cache=writeback,format=raw,id=drive-virtio-data2,werror=stop,rerror=stop -device scsi-hd,bus=scsi2.0,id=virtio-data2,drive=drive-virtio-data2 -device virtio-scsi-pci,id=scsi3 -drive file=disk3.raw,cache=writethrough,if=none,format=raw,id=drive-virtio-data3,werror=stop,rerror=stop -device scsi-hd,bus=scsi3.0,id=virtio-data3,drive=drive-virtio-data3 -device virtio-scsi-pci,id=scsi4 -drive file=disk4.raw,if=none,format=raw,cache=writeback,id=drive-virtio-data4,werror=stop,rerror=stop,readonly=on -device scsi-hd,bus=scsi4.0,id=virtio-data4,drive=drive-virtio-data4 -vnc :1 -vga cirrus -monitor stdio -qmp tcp:0:4444,server,nowait -device virtio-scsi-pci,id=scsiadd -drive file=/home/disk.raw,if=none,id=drive-scsi0-0-add,if=none,media=disk,cache=none,format=raw,werror=stop,aio=native -device scsi-hd,bus=scsiadd.0,drive=drive-scsi0-0-add,id=scsiaddd
Comment 14 Vadim Rozenfeld 2014-11-03 04:31:43 EST
Can we update drivers to build 88 and switch the relevant disk off-line before
trying to unplug virtio-scsi-pci controller?

Thanks,
Vadim,
Comment 15 Min Deng 2014-11-07 04:01:14 EST
(In reply to Vadim Rozenfeld from comment #14)
> Can we update drivers to build 88 and switch the relevant disk off-line
> before
> trying to unplug virtio-scsi-pci controller?
> 
> Thanks,
> Vadim,

   Re-tested the bug with build 93,for detail steps please refer to original steps.
   Actual results,
   There was a message that told "Safe to remove device" no any other improper message while doing unplugging and disk could be removed successfully.
   Expected results,
   The disk could be removed successfully.

   Actions were successfully via QMP and HMP,it should be fixed in build 93(the latest build).
Comment 16 Mike Cao 2014-11-07 04:07:15 EST
(In reply to dengmin from comment #15)
> (In reply to Vadim Rozenfeld from comment #14)
> > Can we update drivers to build 88 and switch the relevant disk off-line
> > before
> > trying to unplug virtio-scsi-pci controller?
> > 
> > Thanks,
> > Vadim,
> 
>    Re-tested the bug with build 93,for detail steps please refer to original
> steps.
>    Actual results,
>    There was a message that told "Safe to remove device" no any other
> improper message while doing unplugging and disk could be removed
> successfully.
>    Expected results,
>    The disk could be removed successfully.
> 
>    Actions were successfully via QMP and HMP,it should be fixed in build
> 93(the latest build).

Since lijin find a regression bug on build 93 ,can you retest w/ virito-win-prewhql-88 ?
Comment 17 Vadim Rozenfeld 2014-11-07 05:23:47 EST
Yes, it will be helpful to know how it works in build 88

Best regards,
Vadim.
Comment 18 Min Deng 2014-11-07 07:11:25 EST
Wit(In reply to Vadim Rozenfeld from comment #17)
> Yes, it will be helpful to know how it works in build 88
> 
> Best regards,
> Vadim.

 Re-tested build 88 still get same results to comments 15,any concerns let me know.

Thanks
Min
Comment 19 Vadim Rozenfeld 2014-11-07 07:51:32 EST
Hi Min,
Thank you for your quick response.
Vadim.

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