Bug 656198 - Can only see 16 virtio ports while assigned 30 virtio serial ports on commandLine
Can only see 16 virtio ports while assigned 30 virtio serial ports on command...
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: qemu-kvm (Show other bugs)
6.0
x86_64 Linux
medium Severity medium
: beta
: 6.1
Assigned To: Amit Shah
Virtualization Bugs
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2010-11-23 03:08 EST by Mike Cao
Modified: 2013-01-09 18:22 EST (History)
8 users (show)

See Also:
Fixed In Version: qemu-kvm-0.12.1.2-2.132.el6
Doc Type: Bug Fix
Doc Text:
while using the virtio-serial device with the number of ports greater than 16, only 16 were seen in the guest. This led to the guest not being able to communicate with the host on the ports beyond the 16th one. This was due to some port instantiation messages getting missed as a result of a small queue size for outstanding requests from the host to guest. The queue size is now increased to 32, enabling more outstanding requests at once. This allows for all of the current maximum 31 ports to be instantiated at once.
Story Points: ---
Clone Of:
Environment:
Last Closed: 2011-05-19 07:28:25 EDT
Type: ---
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 Mike Cao 2010-11-23 03:08:44 EST
Description of problem:


Version-Release number of selected component (if applicable):
host info:
]# uname -r 
2.6.32-71.9.1.el6.x86_64
]# rpm -q qemu-kvm
guest info:
RHEL5.6 32 bit
qemu-kvm-0.12.1.2-2.113.el6_0.4.x86_64


How reproducible:
100%

Steps to Reproduce:
1.Start VM with 30 virtio serial port
CLI:
/usr/libexec/qemu-kvm -M rhel6.0.0 -enable-kvm -m 4G -smp 2 -name RHEL5U6 -uuid 8d26b359-2ea6-413f-2c26-197400d9c9eb -rtc base=utc -boot c -drive file=/dev/vgtest/mike,if=none,id=drive-ide0-0-0,format=raw,cache=none,werror=stop,rerror=stop -device ide-drive,drive=drive-ide0-0-0,id=ide0-0-0 -netdev tap,id=hostnet0 -device e1000,netdev=hostnet0,id=net0,mac=52:54:00:ac:4e:8d -usb -device virtio-balloon-pci,id=balloon0 -vnc :10 -monitor stdio
-device virtio-serial-pci,id=virtio-serial0,max_ports=31,bus=pci.0 \
-chardev pty,id=channel0 -device virtserialport,chardev=channel0,id=port0,bus=virtio-serial0.0 \
-chardev pty,id=channel1 -device virtserialport,chardev=channel1,id=port1,bus=virtio-serial0.0 \
-chardev pty,id=channel2 -device virtserialport,chardev=channel2,id=port2,bus=virtio-serial0.0 \
-chardev pty,id=channel3 -device virtserialport,chardev=channel3,id=port3,bus=virtio-serial0.0 \
-chardev pty,id=channel4 -device virtserialport,chardev=channel4,id=port4,bus=virtio-serial0.0 \
-chardev pty,id=channel5 -device virtserialport,chardev=channel5,id=port5,bus=virtio-serial0.0 \
-chardev pty,id=channel6 -device virtserialport,chardev=channel6,id=port6,bus=virtio-serial0.0 \
-chardev pty,id=channel7 -device virtserialport,chardev=channel7,id=port7,bus=virtio-serial0.0 \
-chardev pty,id=channel8 -device virtserialport,chardev=channel8,id=port8,bus=virtio-serial0.0 \
-chardev pty,id=channel9 -device virtserialport,chardev=channel9,id=port9,bus=virtio-serial0.0 \
-chardev pty,id=channel10 -device virtserialport,chardev=channel10,id=port10,bus=virtio-serial0.0 \
-chardev pty,id=channel11 -device virtserialport,chardev=channel11,id=port11,bus=virtio-serial0.0 \
-chardev pty,id=channel12 -device virtserialport,chardev=channel12,id=port12,bus=virtio-serial0.0 \
-chardev pty,id=channel13 -device virtserialport,chardev=channel13,id=port13,bus=virtio-serial0.0 \
-chardev pty,id=channel14 -device virtserialport,chardev=channel14,id=port14,bus=virtio-serial0.0 \
-chardev pty,id=channel15 -device virtserialport,chardev=channel15,id=port15,bus=virtio-serial0.0 \
-chardev pty,id=channel16 -device virtserialport,chardev=channel16,id=port16,bus=virtio-serial0.0 \
-chardev pty,id=channel17 -device virtserialport,chardev=channel17,id=port17,bus=virtio-serial0.0 \
-chardev pty,id=channel18 -device virtserialport,chardev=channel18,id=port18,bus=virtio-serial0.0 \
-chardev pty,id=channel19 -device virtserialport,chardev=channel19,id=port19,bus=virtio-serial0.0 \
-chardev pty,id=channel20 -device virtserialport,chardev=channel20,id=port20,bus=virtio-serial0.0 \
-chardev pty,id=channel21 -device virtserialport,chardev=channel21,id=port21,bus=virtio-serial0.0 \
-chardev pty,id=channel22 -device virtserialport,chardev=channel22,id=port22,bus=virtio-serial0.0 \
-chardev pty,id=channel23 -device virtserialport,chardev=channel23,id=port23,bus=virtio-serial0.0 \
-chardev pty,id=channel24 -device virtserialport,chardev=channel24,id=port24,bus=virtio-serial0.0 \
-chardev pty,id=channel25 -device virtserialport,chardev=channel25,id=port25,bus=virtio-serial0.0 \
-chardev pty,id=channel26 -device virtserialport,chardev=channel26,id=port26,bus=virtio-serial0.0 \
-chardev pty,id=channel27 -device virtserialport,chardev=channel27,id=port27,bus=virtio-serial0.0 \
-chardev pty,id=channel28 -device virtserialport,chardev=channel28,id=port28,bus=virtio-serial0.0 \
-chardev pty,id=channel29 -device virtserialport,chardev=channel29,id=port29,bus=virtio-serial0.0 

2.in the guest #ls /dev/vport* |wc -l
  
Actual results:
in the /dev ,can only find 16 virtio serial port

Expected results:
after step2,it should be 30

Additional info:
Comment 1 Amit Shah 2010-11-23 03:26:37 EST
Reproduced locally.  This could be a bug in the guest kernel or host qemu.  Will update component after investigation if necessary.
Comment 2 Amit Shah 2010-11-23 04:25:43 EST
(In reply to comment #1)
> Reproduced locally.  This could be a bug in the guest kernel or host qemu. 
> Will update component after investigation if necessary.

Bug is in qemu.  We need to re-try sending control messages if vq is full.
Comment 3 Amit Shah 2011-01-20 22:17:52 EST
Current solution is to increase number of vq buffers for the control queue to 32.  Re-sending buffers (and queueing up) will be looked at later.
Comment 8 Mike Cao 2011-03-08 00:03:59 EST
Verified on qemu-kvm-0.12.1.2-2.148.el6.x86_64 According to the steps in comment #0

Actual Results:
can see 30 virtio-serial-port in the guest


Based on above ,this issue has been fixed.
Comment 10 Miya Chen 2011-03-09 22:27:04 EST
move to verified based on comment#8.
Comment 11 Amit Shah 2011-05-04 06:48:57 EDT
    Technical note added. If any revisions are required, please edit the "Technical Notes" field
    accordingly. All revisions will be proofread by the Engineering Content Services team.
    
    New Contents:
while using the virtio-serial device with the number of ports greater than 16, only 16 were seen in the guest.  This led to the guest not being able to communicate with the host on the ports beyond the 16th one.  This was due to some port instantiation messages getting missed as a result of a small queue size for outstanding requests from the host to guest.  The queue size is now increased to 32, enabling more outstanding requests at once.  This allows for all of the current maximum 31 ports to be instantiated at once.
Comment 12 errata-xmlrpc 2011-05-19 07:28:25 EDT
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHSA-2011-0534.html
Comment 13 errata-xmlrpc 2011-05-19 09:00:34 EDT
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on therefore solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHSA-2011-0534.html

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