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 728878 - Cannot establish connection with unix socket chardev after close several times
Summary: Cannot establish connection with unix socket chardev after close several times
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: qemu-kvm
Version: 6.2
Hardware: Unspecified
OS: Unspecified
high
medium
Target Milestone: rc
: ---
Assignee: Amit Shah
QA Contact: Virtualization Bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-08-08 09:17 UTC by Shaolong Hu
Modified: 2013-01-10 00:11 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2011-12-13 08:57:35 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Shaolong Hu 2011-08-08 09:17:08 UTC
Description of problem:
---------------------------
Boot guest with virtio-serial, attached with a unix socket chardev, guest and host can communicate with it at beginning, after closing connection several times from host side, communication failed.  


Version-Release number of selected component (if applicable):
----------------------------------------------------------------
2.6.32-174.el6.x86_64
qemu-kvm-0.12.1.2-2.175.el6.x86_64


How reproducible:
------------------
100%


Steps to Reproduce:
---------------------
1.boot guest with:
#/usr/libexec/qemu-kvm -enable-kvm -M rhel6.2.0 -smp 4 -m 4G -name rhel6.1-64 -uuid 3f2ea5cd-3d29-48ff-aab2-23df1b6ae213 -drive file=RHEL-Server-6.1-64-virtio.qcow2,cache=none,if=none,rerror=stop,werror=stop,id=drive-virtio-disk0,format=qcow2 -device virtio-blk-pci,drive=drive-virtio-disk0,id=device-virtio-disk0 -netdev tap,script=/etc/qemu-ifup,id=netdev0 -device virtio-net-pci,netdev=netdev0,id=device-net0 -boot order=cd,menu=on -usb -device usb-tablet,id=input0 -spice disable-ticketing,port=5910 -monitor stdio -device virtio-serial-pci,id=virtio-serial0,max_ports=16,bus=pci.0,addr=0x5 -chardev socket,id=channel0,path=/tmp/foo,server,nowait -device virtserialport,chardev=channel0,name=port.0,bus=virtio-serial0.0,id=port0

2.in the host:
#nc -U /tmp/foo > a.out

3.in the guest:
#dd if=/dev/urandom of=test bs=1M count=100
#cat test > /dev/vport0p1

4.First time, it works fine, file cksum matches.

5.In host, stop nc by "ctrl+c", restart nc.

6.In guest:
#cat test > /dev/vport0p1

7.repeat 5-6

Actual results:
-----------------
After step 7 1-2 times, communicate failed.


Expected results:
------------------
Communication should work every time after step 7


Additional info:

Comment 3 Amit Shah 2011-12-09 13:00:51 UTC
Do you wait for the transfer to finish each time before hitting Ctrl+C?

Or do you do it in the middle of the transfer?  If you do it in the middle, do you re-start transfer in guest, or do you let it continue?

Comment 4 Shaolong Hu 2011-12-13 08:57:35 UTC
(In reply to comment #3)
> Do you wait for the transfer to finish each time before hitting Ctrl+C?
> 
> Or do you do it in the middle of the transfer?  If you do it in the middle, do
> you re-start transfer in guest, or do you let it continue?

I find when nc is terminated by "ctrl+c", its process will reside in system, and multiple nc processes cause connection failed, it's necessary to modify our test case to kill nc instead of "ctrl+c", close this as NOTABUG.


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