Hide Forgot
Description of problem: Version-Release number of selected component (if applicable): # uname -r &&rpm -q qemu-kvm 2.6.32-166.el6.x86_64 qemu-kvm-0.12.1.2-2.169.el6.x86_64 How reproducible: 2/2 Steps to Reproduce: 1.prepare a pre-installed guest 2.qemu-img create -f qcow2 test.img 20G 3.start the pre-installed guest with -drive file=test,if=none,id=test1,format=qcow2,cache=none,werror=stop,rerror=stop -device usb-storage,drive=test1,id=test1 3.in the guest fdisk /dev/sda to make it as partition :/dev/sda1 4,mkfs.ext4 /dev/sda1 Actual results: format will never completed.Call trace found in guest dmesg. Expected results: disk could be formatted successfully. Additional info: FUll commandline: /usr/libexec/qemu-kvm -M rhel6.2.0 -enable-kvm -m 1024 -smp 2,sockets=2,cores=1,threads=1 -name Test -uuid 2e426ce8-0cfa-48f7-13df-5cfaa2d15368 -rtc base=utc -boot c -drive file=/var/lib/libvirt/images/Test.img,if=none,id=drive-virtio-disk0,format=raw,cache=none,aio=threads -device virtio-blk-pci,bus=pci.0,addr=0x5,bootindex=1,drive=drive-virtio-disk0,id=virtio-disk0,scsi=on -netdev tap,id=hostnet0,vhost=on -device virtio-net-pci,netdev=hostnet0,id=net0,mac=52:54:00:07:ce:0d,bus=pci.0,addr=0x3 -chardev pty,id=charserial0 -device isa-serial,chardev=charserial0,id=serial0 -usb -device usb-tablet,id=input0 -vnc 0.0.0.0:0 -vga cirrus -device intel-hda,id=sound0,bus=pci.0,addr=0x4 -device hda-duplex,id=sound0-codec0,bus=sound0.0,cad=0 -device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x6 -drive file=test,if=none,id=test1,format=qcow2,cache=none,werror=stop,rerror=stop -device usb-storage,drive=test1,id=test1 -monitor stdio
Created attachment 512168 [details] Call trace in guest dmesg
Tried with -device usb-ehci,id=ehci the problem was gone ,close as not a bug ,sorry for inconvenience
for now we still support usb 1.1 (UHCI controller),reopen this issue Hit this issue with qemu-kvm-tools-0.12.1.2-2.175.el6.x86_64. Command line -usb -device usb-hub,bus=usb.0,port=1 -device usb-storage,bus=usb.0,port=1.1,drive=usbstick1
How long did you wait? Note that usb-storage attached to UHCI is *very* slow, so it will take a while, but it should succeed in the end.
(In reply to comment #4) > How long did you wait? Note that usb-storage attached to UHCI is *very* slow, > so it will take a while, but it should succeed in the end. It costs me 9m15s to format 1GB UHCI usb disk ,
Ok, so it actually works, great. That it can take 10 minutes is normal. You can use smaller disks (such as 32 MB) for USB 1.1 to speed up testing.