Bug 1208175 - Can't connect to console via Horizon - ends up error code 1006
Summary: Can't connect to console via Horizon - ends up error code 1006
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat OpenStack
Classification: Red Hat
Component: openstack-nova
Version: 5.0 (RHEL 6)
Hardware: Unspecified
OS: Unspecified
urgent
high
Target Milestone: async
: 5.0 (RHEL 6)
Assignee: Sahid Ferdjaoui
QA Contact: nlevinki
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2015-04-01 14:51 UTC by Ido Ovadia
Modified: 2019-09-09 13:22 UTC (History)
18 users (show)

Fixed In Version: openstack-nova-2014.1.4-4.el6ost
Doc Type: Bug Fix
Doc Text:
Clone Of:
: 1217898 (view as bug list)
Environment:
Last Closed: 2015-05-04 14:12:30 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
nova-consoleauth.log (140.23 KB, text/plain)
2015-04-01 14:51 UTC, Ido Ovadia
no flags Details
nova.conf (100.30 KB, text/plain)
2015-04-19 09:39 UTC, Ido Ovadia
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Red Hat Knowledge Base (Solution) 1432173 0 None None None Never
Red Hat Product Errata RHBA-2015:0923 0 normal SHIPPED_LIVE openstack-nova bug fix advisory 2015-05-04 18:12:18 UTC

Description Ido Ovadia 2015-04-01 14:51:16 UTC
Created attachment 1009716 [details]
nova-consoleauth.log

Description of problem:
=======================
Unable to get to the VNC console of the launched instance - get: Failed to connect to server (code: 1006)


Version-Release number of selected component:
=============================================
python-django-horizon-2014.1.4-1.el6ost.noarch
openstack-dashboard-2014.1.4-1.el6ost.noarch
openstack-nova-novncproxy-2014.1.4-3.el6ost.noarch
openstack-nova-console-2014.1.4-3.el6ost.noarch
openstack-packstack-2014.1.1-0.46.dev1280.el6ost.noarch

How reproducible:
=================
100%

Steps to Reproduce:
===================
1. Install openstack all-in-one using packstack
2. Launch an instance
3. Open an instance console  

Actual results:
===============
Failed to connect to server (code: 1006)

Expected results:
=================
Console opened successfully

Additional info:
================
Setting selinux Permissive doesn't fix that bug

Log file is enclosed

Comment 4 Sahid Ferdjaoui 2015-04-07 14:07:19 UTC
This seems to be a configuration issue with nova and since you are using packstack the bug should probably be addressed to it.

Can you provide to me your nova.conf or at least these options:

  smy_ip=
  novnc_enabled=
  novncproxy_base_url=
  novncproxy_port=
  vncserver_proxyclient_address=
  vncserver_listen=

Thanks

Comment 5 Ido Ovadia 2015-04-19 09:39:04 UTC
Created attachment 1016012 [details]
nova.conf

Comment 6 Sahid Ferdjaoui 2015-04-20 12:51:42 UTC
We have an exception reported by websocketproxy.py. I believe all console are broken.

  7: handler exception: _() takes exactly 1 argument (2 given)
  7: Traceback (most recent call last):
  File "/usr/lib/python2.6/site-packages/websockify/websocket.py", line 711, in top_new_client
    self.new_client()
  File "/usr/lib/python2.6/site-packages/nova/console/websocketproxy.py", line 116, in new_client
    self.msg(_('connect info: %s', str(connect_info)))
TypeError: _() takes exactly 1 argument (2 given)

This bug has been introduced on RHOS5(8d117e9e) during the backport of the feature serial-console. It seems that the method "msg" cannot accepts an extra argument to format the log message.

A fix will be addressed downstream only.

Comment 7 Sahid Ferdjaoui 2015-04-20 14:17:06 UTC
Made a mistake on the copy/past, there is the real Traceback:

37: Traceback (most recent call last):
  File "/usr/lib/python2.6/site-packages/websockify/websocket.py", line 711, in top_new_client
    self.new_client()
  File "/usr/lib/python2.6/site-packages/nova/console/websocketproxy.py", line 116, in new_client
    self.msg(_('connect info: %s'), str(connect_info))
TypeError: msg() takes exactly 2 arguments (3 given)

Comment 8 Matt Riedemann 2015-04-22 13:40:39 UTC
What version of websockify is installed?

The minimum required version in stable/juno for nova is 0.6.0:

https://github.com/openstack/nova/blob/stable/juno/requirements.txt#L36

so you'd hit this:

https://github.com/kanaka/websockify/blob/v0.6.0/websockify/websocket.py#L270

Comment 9 Matt Riedemann 2015-04-22 13:45:49 UTC
Oops, this is icehouse, so there are different minimum versions:

https://github.com/openstack/nova/blob/2014.1.4/requirements.txt#L30

websockify>=0.5.1,<0.6

https://github.com/openstack/nova/blob/2014.1.4/nova/console/websocketproxy.py#L107

If you have websockify 0.5.1 it looks like you'd be OK:

https://github.com/kanaka/websockify/blob/v0.5.1/websockify/websocket.py#L390

But anything newer and you'd be busted.

Comment 10 Matt Riedemann 2015-04-22 13:49:19 UTC
File "/usr/lib/python2.6/site-packages/nova/console/websocketproxy.py", line 116, in new_client
    self.msg(_('connect info: %s'), str(connect_info))

^ is not 2014.1.4 level code in the nova in the community, so my guess is RHOSP backported some changes to it's stable icehouse release which were not compatible with the version of websockify being shipped.  But that's conjecture, I don't work for Red Hat.

Comment 14 nlevinki 2015-05-03 08:11:47 UTC
Installed openstack
created a vm via the GUI.
Connected to the vm via the console window.

Comment 16 errata-xmlrpc 2015-05-04 14:12:30 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHBA-2015-0923.html


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