Bug 1748177

Summary: Websocket should be true when using connect qemu with vnc websocket client
Product: Red Hat Enterprise Linux 8 Reporter: Guo, Zhiyi <zhguo>
Component: qemu-kvmAssignee: Ademar Reis <areis>
Status: CLOSED DEFERRED QA Contact: Virtualization Bugs <virt-bugs>
Severity: low Docs Contact:
Priority: low    
Version: 8.1CC: coli, juzhang, kraxel, rbalakri, ribarry, virt-maint, yafu
Target Milestone: rc   
Target Release: ---   
Hardware: x86_64   
OS: All   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: 1748175 Environment:
Last Closed: 2019-09-03 20:38:42 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 1748175    
Bug Blocks:    

Description Guo, Zhiyi 2019-09-03 05:55:49 UTC
+++ This bug was initially created as a clone of Bug #1748175 +++

Description of problem:
Websocket should be true when using connect qemu with vnc websocket client

Version-Release number of selected component (if applicable):
qemu-kvm-4.1.0-5.module+el8.1.0+4076+b5e41ebc.x86_64

How reproducible:
100%

Steps to Reproduce:
1.start qeumu with cli:
# /usr/libexec/qemu-kvm -vnc 0.0.0.0:66,websocket=5766 -qmp tcp:0.0.0.0:8888,server,nowait
2.launch a qmp connection:
# telnet 0.0.0.0 8888
Trying 0.0.0.0...
Connected to 0.0.0.0.
Escape character is '^]'.
{"QMP": {"version": {"qemu": {"micro": 0, "minor": 1, "major": 4}, "package": "qemu-kvm-4.1.0-5.module+el8.1.0+4076+b5e41ebc"}, "capabilities": ["oob"]}}
{ "execute": "qmp_capabilities" }
{"return": {}}
3.Connect vnc websocket client(onVNC) to qemu
4.query vnc status from qmp:
{ "execute": "query-vnc" }


Actual results:
After step 3, qmp event generated:
{"timestamp": {"seconds": 1567488791, "microseconds": 769737}, "event": "VNC_CONNECTED", "data": {"server": {"auth": "none", "family": "ipv4", "service": "5966", "host": "0.0.0.0", "websocket": false}, "client": {"family": "ipv4", "service": "54279", "host": "10.66.8.137", "websocket": false}}}
{"timestamp": {"seconds": 1567488791, "microseconds": 778450}, "event": "VNC_INITIALIZED", "data": {"server": {"auth": "none", "family": "ipv4", "service": "5966", "host": "0.0.0.0", "websocket": false}, "client": {"family": "ipv4", "service": "54279", "host": "10.66.8.137", "websocket": false}}}

It prompts websocket is not enabled and vnc client is not using websocket

After step 4, vnc status:
{"return": {"enabled": true, "auth": "none", "family": "ipv4", "clients": [{"family": "ipv4", "service": "54279", "host": "10.66.8.137", "websocket": true}], "service": "5966", "host": "0.0.0.0"}}

It prompts vnc client is a websocket client

Expected results:
Websocket should be true in qmp event 

Additional info:

--- Additional comment from Guo, Zhiyi on 2019-09-03 05:53:02 UTC ---

This is not a regression and not a blocker I think. It can be reproduced on old qemu version qemu-kvm-rhev-2.9.0-16.el7_4.3.x86_64