Bug 986236 - fail to transfer big size data from host to guest via virtconsole with unix socket
fail to transfer big size data from host to guest via virtconsole with unix s...
Status: CLOSED WONTFIX
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: qemu-kvm (Show other bugs)
6.5
Unspecified Unspecified
medium Severity medium
: rc
: ---
Assigned To: Virtualization Maintenance
Virtualization Bugs
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2013-07-19 05:48 EDT by Sibiao Luo
Modified: 2013-07-29 08:56 EDT (History)
12 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-07-19 06:50:34 EDT
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)

  None (edit)
Description Sibiao Luo 2013-07-19 05:48:16 EDT
Description of problem:
fail to transfer big size data from host to guest via virtconsole with unix socket, but can complete transfer big size data from guest to host via virtconsole with unix socket, just the md5 value not the same.
BTW, it can transfer character string from host to guest or from guest to host successfully.

Version-Release number of selected component (if applicable):
host info:
kernel-2.6.32-398.el6.x86_64
qemu-kvm-0.12.1.2-2.378.el6.x86_64
guest info:
kernel-2.6.32-398.el6.x86_64

How reproducible:
always

Steps to Reproduce:
1.boot guest with virconsole with unix socket.
e.g:...-device virtio-serial-pci,id=virtio-serial0,max_ports=16,vectors=0,bus=pci.0,addr=0x3 -chardev socket,id=foo,path=/tmp/foo,server,nowait -device virtconsole,chardev=foo,name=com.redhat.rhevm.vdsm.1,bus=virtio-serial0.0,id=port1,nr=1
2.transfer big size data from host to guest.
host ]# ls -lh test-file 
-rw-r--r--. 1 root root 2.0G Jul 17 10:59 test-file
host ]# cat test-file | nc -U /tmp/foo 
^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^C
guest]# cat /dev/hvc0 >> recieve1
^C
guest]# ls -lh recieve1 
-rw-r--r--. 1 root root 0 Jul 20 01:24 recieve1  <----------zero byte
3.transfer big size data from guest to host.
guest]# ls -lh guest-file 
-rw-r--r--. 1 root root 2.0G Jul 17 19:10 guest-file
guest]# md5sum guest-file 
f3444be3893c1b9b6fa9dd1acde671a9  guest-file <--------------+
                                                            |
guest]# cat guest-file > /dev/hvc0                          | 
host ]# nc -U /tmp/foo >> recieve1                          |
^C                                                          |
host ]# ls -lh recieve1                                     |
-rw-r--r--. 1 root root 2.0G Jul 19 17:26 recieve1          |
host ]# md5sum recieve1                                     |
033164af5d9077fbe3ca5bae9fe4eaf3  recieve1   ---------------+
                                                            |
guest]# cat guest-file > /dev/hvc0                          |  
host ]# nc -U /tmp/foo >> recieve2                          | 
^C                                                          |
host ]# ls -lh recieve2                                     |
-rw-r--r--. 1 root root 2.0G Jul 19 17:27 recieve2          |
host ]# md5sum recieve2                                     |
8c24f04b305293a6871e4ed4e0b740cf  recieve2   ---------------+

4.transfer big size data from host to guest again.
host ]# ls -lh test-file 
-rw-r--r--. 1 root root 2.0G Jul 17 10:59 test-file
host ]# cat test-file | nc -U /tmp/foo
^@^@^@^@^@^C
guest]# cat /dev/hvc0 >> recieve1
^C
guest]# ls -lh recieve1 
-rw-r--r--. 1 root root 0 Jul 20 01:24 recieve1  <----------zero byte

Actual results:
from step 2 and 4, it cann't transfer big data from host to guest at all.
from step 3, it can complete to transfer from guest to host, just the md5sum not the same.

Expected results:
it should complete transfer big data between host and guest successfully, the md5 value should be keeped the same.

Additional info:
# /usr/libexec/qemu-kvm -S -M rhel6.5.0 -cpu SandyBridge -enable-kvm -m 4096 -smp 4,sockets=2,cores=2,threads=1 -no-kvm-pit-reinjection -name sluo -uuid 43425b70-86e5-4664-bf2c-3b76699b8bec -rtc base=localtime,clock=host,driftfix=slew -device virtio-serial-pci,id=virtio-serial0,max_ports=16,vectors=0,bus=pci.0,addr=0x3 -chardev socket,id=foo,path=/tmp/foo,server,nowait -device virtconsole,chardev=foo,name=com.redhat.rhevm.vdsm.1,bus=virtio-serial0.0,id=port1,nr=1 -drive file=/home/RHEL6.5-20130712.n.0-6.5-Server-x64.qcow2,if=none,id=drive-system-disk,format=qcow2,cache=none,aio=native,werror=stop,rerror=stop,serial="QEMU-DISK1" -device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x4,drive=drive-system-disk,id=system-disk,bootindex=1 -device virtio-balloon-pci,id=ballooning,bus=pci.0,addr=0x5 -global PIIX4_PM.disable_s3=0 -global PIIX4_PM.disable_s4=0 -netdev tap,id=hostnet0,vhost=on,script=/etc/qemu-ifup -device virtio-net-pci,netdev=hostnet0,id=virtio-net-pci0,mac=2C:41:38:B6:40:21,bus=pci.0,addr=0x6,bootindex=2 -drive file=/home/my-data-disk.qcow2,if=none,id=drive-data-disk,format=qcow2,cache=none,aio=native,werror=stop,rerror=stop,serial="QEMU-DISK2" -device virtio-blk-pci,scsi=off,bus=pci.0,addr=0x7,drive=drive-data-disk,id=data-disk,bootindex=3 -k en-us -boot menu=on -qmp tcp:0:4444,server,nowait -vnc :1 -spice port=5931,disable-ticketing -monitor stdio
Comment 1 Sibiao Luo 2013-07-19 06:02:58 EDT
(In reply to Sibiao Luo from comment #0)
I can transfer character string from host to guest or from guest to host successfully via virtconsole with unix socket .

host----->guest:
host ]# echo "sibiaoluo" | nc -U /tmp/foo 
host ]# echo "sibiaoluo" | nc -U /tmp/foo 
host ]# echo "sibiaoluo" | nc -U /tmp/foo 
guest]# cat /dev/hvc0
sibiaoluo
sibiaoluo
sibiaoluo
^C

guest---->host:
guest]# echo "sibiaoluo" > /dev/hvc0
guest]# echo "sibiaoluo" > /dev/hvc0
guest]# echo "sibiaoluo" > /dev/hvc0
host ]# nc -U /tmp/foo
sibiaoluo
sibiaoluo
sibiaoluo
^C
Comment 2 Amit Shah 2013-07-19 06:50:34 EDT
Let's not try transferring files or bulk data via console ports.

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