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 989848 - qemu should give friendly prompt when specify invalid vnc port value
Summary: qemu should give friendly prompt when specify invalid vnc port value
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: qemu-kvm
Version: 6.5
Hardware: Unspecified
OS: Unspecified
low
low
Target Milestone: rc
: ---
Assignee: Virtualization Maintenance
QA Contact: Virtualization Bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-07-30 04:24 UTC by Sibiao Luo
Modified: 2013-08-01 23:36 UTC (History)
12 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-08-01 23:36:29 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Sibiao Luo 2013-07-30 04:24:30 UTC
Description of problem:
If specify invalid vnc port value in qemu-kvm command line, the qemu should quit with friendly prompt. Also tried the spice that has no such issue.

Version-Release number of selected component (if applicable):
host info:
2.6.32-402.el6.x86_64
qemu-kvm-0.12.1.2-2.381.el6.x86_64
seabios-0.6.1.2-28.el6.x86_64

How reproducible:
100%

Steps to Reproduce:
...-vnc host:display
If you do not specify host, connections will be accepted from any host, The TCP port on which the VNC session is then running is normally a 5900 + display number.  

1.# /usr/libexec/qemu-kvm -vnc :aaaa -monitor stdio
QEMU 0.12.1 monitor - type 'help' for more information
(qemu) info vnc
Server:
     address: 0.0.0.0:5900
        auth: none
Client: none
(qemu) q

2.# /usr/libexec/qemu-kvm -vnc :99999999999 -monitor stdio
QEMU 0.12.1 monitor - type 'help' for more information
(qemu) info vnc
Server:
     address: 0.0.0.0:65291
        auth: none
Client: none
(qemu) q

3.# /usr/libexec/qemu-kvm -vnc :-10 -monitor stdio
QEMU 0.12.1 monitor - type 'help' for more information
(qemu) info vnc
Server:
     address: 0.0.0.0:5890
        auth: none
Client: none
(qemu) q

4.# /usr/libexec/qemu-kvm -vnc :-999 -monitor stdio
QEMU 0.12.1 monitor - type 'help' for more information
(qemu) info vnc
Server:
     address: 0.0.0.0:4901
        auth: none
Client: none
(qemu) 
5.# /usr/libexec/qemu-kvm -vnc :-9999 -monitor stdio
Failed to start VNC server on `:-9999': address resolution failed for :-4099: Servname not supported for ai_socktype

Actual results:


Expected results:
Qemu should quit with a friendly prompt, like:
for step 1, qemu quit with prompt: Parameter 'port' expects a number
for step 2, qemu quit with prompt: -vnc port value is out of range
...

Additional info:
Also tried the spice, testing as following.
# /usr/libexec/qemu-kvm -spice port=999999999,disable-ticketing -monitor stdio
spice port is out of range

# /usr/libexec/qemu-kvm -spice port=aaaa,disable-ticketing -monitor stdio
qemu-kvm: -spice port=aaaa,disable-ticketing: Parameter 'port' expects a number
parse error: port=aaaa,disable-ticketing
 
# /usr/libexec/qemu-kvm -spice port=-9999,disable-ticketing -monitor stdio
spice port is out of range

# /usr/libexec/qemu-kvm -spice port=-1,disable-ticketing -monitor stdio
spice port is out of range

# /usr/libexec/qemu-kvm -spice port=0,disable-ticketing -monitor stdio
neither port nor tls-port specified for spice.

# /usr/libexec/qemu-kvm -spice port=1,disable-ticketing -monitor stdio
QEMU 0.12.1 monitor - type 'help' for more information
(qemu) info spice
Server:
     migrated: false
     address: 0.0.0.0:1
        auth: none
Channels: none
(qemu) q

Comment 2 Ademar Reis 2013-08-01 23:36:29 UTC
corner case, not a customer issue, so WONTFIX for RHEL6 (there's already a bug for RHEL7: bug 733600).


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