Bug 596014 - hot add virtio-blk-pci via device_add lead to virtio network lost
Summary: hot add virtio-blk-pci via device_add lead to virtio network lost
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: qemu-kvm
Version: 6.0
Hardware: All
OS: Linux
Target Milestone: rc
: ---
Assignee: Alex Williamson
QA Contact: Virtualization Bugs
Depends On: 581963
TreeView+ depends on / blocked
Reported: 2010-05-26 06:34 UTC by juzhang
Modified: 2013-01-09 22:37 UTC (History)
5 users (show)

Fixed In Version: qemu-kvm-
Doc Type: Bug Fix
Doc Text:
Clone Of:
Last Closed: 2010-07-08 06:59:44 UTC
Target Upstream Version:

Attachments (Terms of Use)

Description juzhang 2010-05-26 06:34:43 UTC
Description of problem:
hot add virtio-blk-pci via device_add lead to virtio network lost.

Version-Release number of selected component (if applicable):
#uname -r
#rpm -q qemu-kvm
guest: rhel6.0

How reproducible:

Steps to Reproduce:
1.boot guest
/usr/libexec/qemu-kvm  -no-hpet -usbdevice tablet -rtc-td-hack -m 2G -smp 2 -drive file=/root/zhangjunyi/RHEL-Server-6.0-64-virtio.qcow2,if=virtio,boot=on,id=test,cache=none,werror=stop,rerror=stop -net nic,vlan=0,macaddr=22:11:22:45:66:22,model=virtio -net tap,vlan=0,script=/etc/qemu-ifup -uuid `uuidgen` -cpu qemu64,+sse2 -balloon none -boot c -monitor stdio -vnc :10
2. hot add drive
(qemu) drive_add bus file=/root/zhangjunyi/test1.qcow2,format=qcow2,if=none,id=test1
3. hot add  virtio-blk-pci
(qemu) device_add virtio-blk-pci,drive=test1
Actual results:
before step 3, guest's network is ok and can ssh to guest.

ping guest
PING ( 56(84) bytes of data.
64 bytes from icmp_seq=1 ttl=64 time=1.96 ms
64 bytes from icmp_seq=2 ttl=64 time=0.491 ms

after step 3,guest's network was lost.

ping guest
PING ( 56(84) bytes of data.
From icmp_seq=1 Destination Host Unreachable
From icmp_seq=2 Destination Host Unreachable
From icmp_seq=3 Destination Host Unreachable

Expected results:
virtio network is not reflected when hot add virtio-blk-pci.

Additional info:
Pleas NOTE:
hot add virtio-blk-pci via device_add only lead to virtio network lost.
for e1000 and rtl8139 are not reflected.

Comment 2 RHEL Program Management 2010-05-28 10:55:37 UTC
This request was evaluated by Red Hat Product Management for inclusion in a Red
Hat Enterprise Linux major release.  Product Management has requested further
review of this request by Red Hat Engineering, for potential inclusion in a Red
Hat Enterprise Linux Major release.  This request is not yet committed for

Comment 3 Alex Williamson 2010-06-16 05:20:39 UTC
Already fixed upstream

Comment 7 juzhang 2010-07-08 06:58:29 UTC
Verified on qemu-kvm-
Because of drive_add was disabled,using __com.redhat_drive_add instead of drive_add.


1.boot guest
/usr/libexec/qemu-kvm -m 4G -smp 4 -drive file=/root/zhangjunyi/rhel6.64.qcow2,if=none,id=drive-virtio-disk0,boot=on,cache=none,format=qcow2 -device virtio-blk-pci,bus=pci.0,drive=drive-virtio-disk0,id=virtio-disk0  -device virtio-balloon-pci -cpu qemu64,+sse2,+x2apic -monitor stdio -vnc :10 -qmp tcp:0:4445,server,nowait -drive file=/root/zhangjunyi/boot.iso,if=none,media=cdrom,id=drive-ide0-1-0,readonly=on,format=raw -device ide-drive,drive=drive-ide0-1-0 -boot order=dcn,menu=on -netdev tap,id=hostnet0,vhost=on -device virtio-net-pci,netdev=hostnet0,id=net0,mac=22:11:22:45:66:97

2. hot add drive
{"execute":"__com.redhat_drive_add", "arguments": {"file":"/root/zhangjunyi/test1.qcow2","format":"qcow2","id":"test1"}}

3.hot add  virtio-blk-pci

network is still ok.

Comment 8 juzhang 2010-07-08 06:59:44 UTC
according to comment7,close this issue.

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