Crossbar.io - issue starting crossbar

#1

All,

I have installed crossbar successfully several times on Ubuntu based systems in the past. However, I am attempting to deploy crossbar onto a copy of a production server without success. I鈥檝e been working this problem for 4+ hours now. Hopefully someone will recognize this problem. :slight_smile:

I am new to python, however I do have 20+ years of UNIX experience.

路路路

OS details


hostname_redacted opt # lsb_release -a

No LSB modules are available.

Distributor ID: Ubuntu

Description: Ubuntu 12.04.5 LTS

Release: 12.04

Codename: precise


Check Python version


hostname_redacted opt # python --version

Python 2.7.3


Verify hosts entry


hostname_redacted opt # cat /etc/hosts

This host鈥檚 names (localhost)

127.0.0.1 localhost

This host

x.x.x.x hostname_redacted


Check crossbar versions


hostname_redacted opt # crossbar version

Crossbar.io package versions and platform information:

Crossbar.io : 0.9.11

Autobahn>Python : 0.9.3-3

WebSocket UTF8 Validator : wsaccel-0.6.2

WebSocket XOR Masker : wsaccel-0.6.2

WAMP JSON Codec : ujson-1.33

WAMP MsgPack Codec : msgpack-python-0.1.10

Twisted : 14.0.2-EPollReactor

Python : 2.7.3-CPython

OS : Linux-3.13.0-39-generic-x86_64-with-Ubuntu-12.04-precise

Machine : x86_64


Generate app


hostname_redacted opt # crossbar init --template hello:python --appdir crossbar_hello

Crossbar.io application directory 鈥榗rossbar_hello鈥 created

Initializing application template 鈥榟ello:python鈥 in directory 鈥/opt/crossbar_hello鈥

Using template from 鈥/usr/local/lib/python2.7/dist-packages/crossbar/templates/hello/python鈥

Creating directory /opt/crossbar_hello/.crossbar

Creating directory /opt/crossbar_hello/hello

Creating file /opt/crossbar_hello/MANIFEST.in

Creating file /opt/crossbar_hello/README.md

Creating file /opt/crossbar_hello/setup.py

Creating file /opt/crossbar_hello/.crossbar/config.json

Creating directory /opt/crossbar_hello/hello/web

Creating file /opt/crossbar_hello/hello/init.py

Creating file /opt/crossbar_hello/hello/hello.py

Creating file /opt/crossbar_hello/hello/web/autobahn.min.js

Creating file /opt/crossbar_hello/hello/web/index.html

Application template initialized

To start your node, run 鈥榗rossbar start --cbdir /opt/crossbar_hello/.crossbar鈥


Change port to 8888 (existing service on 8080)


hostname_redacted opt # sed -i -e 鈥渟/8080/8888/g鈥 crossbar_hello/.crossbar/config.json


Verify changes / show configuration


hostname_redacted opt # cat crossbar_hello/.crossbar/config.json

{

鈥渃ontroller鈥: {

},

鈥渨orkers鈥: [

{

鈥渢ype鈥: 鈥渞outer鈥,

鈥渙ptions鈥: {

鈥減ythonpath鈥: ["鈥"]

},

鈥渞ealms鈥: [

{

鈥渘ame鈥: 鈥渞ealm1鈥,

鈥渞oles鈥: [

{

鈥渘ame鈥: 鈥渁nonymous鈥,

鈥減ermissions鈥: [

{

鈥渦ri鈥: 鈥*鈥,

鈥減ublish鈥: true,

鈥渟ubscribe鈥: true,

鈥渃all鈥: true,

鈥渞egister鈥: true

}

]

}

]

}

],

鈥渢ransports鈥: [

{

鈥渢ype鈥: 鈥渨eb鈥,

鈥渆ndpoint鈥: {

鈥渢ype鈥: 鈥渢cp鈥,

鈥減ort鈥: 8888

},

鈥減aths鈥: {

鈥/鈥: {

鈥渢ype鈥: 鈥渟tatic鈥,

鈥渄irectory鈥: 鈥溾/hello/web鈥

},

鈥渨s鈥: {

鈥渢ype鈥: 鈥渨ebsocket鈥

}

}

}

]

},

{

鈥渢ype鈥: 鈥渃ontainer鈥,

鈥渙ptions鈥: {

鈥減ythonpath鈥: ["鈥"]

},

鈥渃omponents鈥: [

{

鈥渢ype鈥: 鈥渃lass鈥,

鈥渃lassname鈥: 鈥渉ello.hello.AppSession鈥,

鈥渞ealm鈥: 鈥渞ealm1鈥,

鈥渢ransport鈥: {

鈥渢ype鈥: 鈥渨ebsocket鈥,

鈥渆ndpoint鈥: {

鈥渢ype鈥: 鈥渢cp鈥,

鈥渉ost鈥: 鈥127.0.0.1鈥,

鈥減ort鈥: 8888

},

鈥渦rl鈥: 鈥渨s://127.0.0.1:8888/ws鈥

}

}

]

}

]

}


Start crossbar


hostname_redacted opt # crossbar start --cbdir /opt/crossbar_hello/.crossbar

2014-12-01 13:00:32-0500 [Controller 14417] Log opened.

2014-12-01 13:00:32-0500 [Controller 14417] ============================== Crossbar.io ==============================

2014-12-01 13:00:32-0500 [Controller 14417] Crossbar.io 0.9.11 starting

2014-12-01 13:00:32-0500 [Controller 14417] Running on CPython using EPollReactor reactor

2014-12-01 13:00:32-0500 [Controller 14417] Starting from node directory /opt/crossbar_hello/.crossbar

2014-12-01 13:00:32-0500 [Controller 14417] Traceback (most recent call last):

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/bin/crossbar鈥, line 9, in

2014-12-01 13:00:32-0500 [Controller 14417] load_entry_point(鈥榗rossbar==0.9.11鈥, 鈥榗onsole_scripts鈥, 鈥榗rossbar鈥)()

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/crossbar/controller/cli.py鈥, line 410, in run

2014-12-01 13:00:32-0500 [Controller 14417] options.func(options)

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/crossbar/controller/cli.py鈥, line 223, in run_command_start

2014-12-01 13:00:32-0500 [Controller 14417] from crossbar.controller.node import Node

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/crossbar/controller/node.py鈥, line 43, in

2014-12-01 13:00:32-0500 [Controller 14417] from crossbar.controller.process import NodeControllerSession

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/crossbar/controller/process.py鈥, line 55, in

2014-12-01 13:00:32-0500 [Controller 14417] from crossbar.common.process import NativeProcessSession

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/crossbar/common/process.py鈥, line 68, in

2014-12-01 13:00:32-0500 [Controller 14417] from crossbar.twisted.endpoint import create_listening_port_from_config

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/crossbar/twisted/endpoint.py鈥, line 46, in

2014-12-01 13:00:32-0500 [Controller 14417] from crossbar.twisted.tlsctx import TlsServerContextFactory, \

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/crossbar/twisted/tlsctx.py鈥, line 23, in

2014-12-01 13:00:32-0500 [Controller 14417] from twisted.internet.ssl import DefaultOpenSSLContextFactory

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/twisted/internet/ssl.py鈥, line 223, in

2014-12-01 13:00:32-0500 [Controller 14417] from twisted.internet._sslverify import (

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/twisted/internet/_sslverify.py鈥, line 184, in

2014-12-01 13:00:32-0500 [Controller 14417] verifyHostname, VerificationError = _selectVerifyImplementation()

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/twisted/internet/_sslverify.py鈥, line 159, in _selectVerifyImplementation

2014-12-01 13:00:32-0500 [Controller 14417] from service_identity import VerificationError

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/service_identity/init.py鈥, line 12, in

2014-12-01 13:00:32-0500 [Controller 14417] from . import pyopenssl

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/service_identity/pyopenssl.py鈥, line 12, in

2014-12-01 13:00:32-0500 [Controller 14417] from pyasn1_modules.rfc2459 import GeneralNames

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/pyasn1_modules/rfc2459.py鈥, line 72, in

2014-12-01 13:00:32-0500 [Controller 14417] class AttributeValue(univ.Any): pass

2014-12-01 13:00:32-0500 [Controller 14417] AttributeError: 鈥榤odule鈥 object has no attribute 鈥楢ny鈥

EOF

Thank you for your time and assistance.

Shannon Haworth

0 Likes

#2

Hi Shannon,

2014-12-01 13:00:32-0500 [Controller 14417] from service_identity
import VerificationError
2014-12-01 13:00:32-0500 [Controller 14417] File
"/usr/local/lib/python2.7/dist-packages/service_identity/__init__.py",
line 12, in <module>
2014-12-01 13:00:32-0500 [Controller 14417] from . import pyopenssl
2014-12-01 13:00:32-0500 [Controller 14417] File
"/usr/local/lib/python2.7/dist-packages/service_identity/pyopenssl.py",
line 12, in <module>
2014-12-01 13:00:32-0500 [Controller 14417] from
pyasn1_modules.rfc2459 import GeneralNames
2014-12-01 13:00:32-0500 [Controller 14417] File
"/usr/local/lib/python2.7/dist-packages/pyasn1_modules/rfc2459.py", line
72, in <module>
2014-12-01 13:00:32-0500 [Controller 14417] class
AttributeValue(univ.Any): pass
2014-12-01 13:00:32-0500 [Controller 14417] AttributeError: 'module'
object has no attribute 'Any'

Could you try:

sudo pip install -U pyasn1

?

It seems, you've been installing Crossbar.io and all it's dependencies into the system locations of the system Python.

This "works" but is not recommended in general - e.g. when anything else but Crossbar.io runs on the systems - since you are using an old Ubuntu, installing/updating packages in the system locations is "not nice beahvior".

Anyway: the way above situations (old system Python/libs and/or don't overwrite sys stuff) is by using virtualenv.

I can lead you throught that process .. I'll answer you other mail.

Let me know if above helps,
/Tobias

0 Likes

#3

Tobias,

Thank you for your prompt reply. I really need to learn the Python ecosystem.

Here are the results of your suggestion:

# pip install -U pyasn1

Downloading/unpacking pyasn1

Downloading pyasn1-0.1.7.tar.gz (68Kb): 68Kb downloaded

Running setup.py egg_info for package pyasn1

Installing collected packages: pyasn1

Found existing installation: pyasn1 0.0.11a

Uninstalling pyasn1:

  Successfully uninstalled pyasn1

Running setup.py install for pyasn1

Successfully installed pyasn1

Cleaning up鈥

路路路

Followed by


# crossbar start --cbdir /opt/crossbar_hello/.crossbar

2014-12-02 11:16:37-0500 [Controller 30434] Log opened.

2014-12-02 11:16:37-0500 [Controller 30434] ============================== Crossbar.io ==============================

2014-12-02 11:16:37-0500 [Controller 30434] Crossbar.io 0.9.11 starting

2014-12-02 11:16:37-0500 [Controller 30434] Running on CPython using EPollReactor reactor

2014-12-02 11:16:37-0500 [Controller 30434] Starting from node directory /opt/crossbar_hello/.crossbar

2014-12-02 11:16:42-0500 [Controller 30434] Starting from local configuration 鈥/opt/crossbar_hello/.crossbar/config.json鈥

2014-12-02 11:16:42-0500 [Controller 30434] Warning: process utilities not available

2014-12-02 11:16:42-0500 [Controller 30434] No WAMPlets detected in enviroment.

2014-12-02 11:16:43-0500 [Controller 30434] Starting Router with ID 鈥榳orker1鈥 鈥

2014-12-02 11:16:43-0500 [Controller 30434] Entering reactor event loop 鈥

2014-12-02 11:16:43-0500 [Router 30437] Log opened.

2014-12-02 11:16:43-0500 [Router 30437] Running under CPython using EPollReactor reactor

2014-12-02 11:16:49-0500 [Router 30437] Entering event loop 鈥

2014-12-02 11:16:49-0500 [Router 30437] Warning: process utilities not available

2014-12-02 11:16:51-0500 [Router 30437] Connection to node controller lost.

2014-12-02 11:16:51-0500 [Controller 30434] Worker 30437: Process connection gone (A process has ended with a probable error condition: process ended with exit code 1.)

2014-12-02 11:16:51-0500 [Controller 30434] ERROR: failed to start native worker - A process has ended with a probable error condition: process ended with exit code 1.

2014-12-02 11:16:51-0500 [Controller 30434] Traceback (most recent call last):

2014-12-02 11:16:51-0500 [Controller 30434] File 鈥/usr/local/lib/python2.7/dist-packages/crossbar/controller/node.py鈥, line 187, in run_node_config

2014-12-02 11:16:51-0500 [Controller 30434] yield self._run_node_config(config)

2014-12-02 11:16:51-0500 [Controller 30434] File 鈥/usr/local/lib/python2.7/dist-packages/twisted/internet/defer.py鈥, line 1097, in _inlineCallbacks

2014-12-02 11:16:52-0500 [Controller 30434] result = result.throwExceptionIntoGenerator(g)

2014-12-02 11:16:52-0500 [Controller 30434] File 鈥/usr/local/lib/python2.7/dist-packages/twisted/python/failure.py鈥, line 389, in throwExceptionIntoGenerator

2014-12-02 11:16:52-0500 [Controller 30434] return g.throw(self.type, self.value, self.tb)

2014-12-02 11:16:52-0500 [Controller 30434] File 鈥/usr/local/lib/python2.7/dist-packages/crossbar/controller/node.py鈥, line 257, in _run_node_config

2014-12-02 11:16:52-0500 [Controller 30434] yield self._controller.start_router(worker_id, worker_options, details = call_details)

2014-12-02 11:16:52-0500 [Controller 30434] File 鈥/usr/local/lib/python2.7/dist-packages/twisted/internet/defer.py鈥, line 577, in _runCallbacks

2014-12-02 11:16:52-0500 [Controller 30434] current.result = callback(current.result, *args, **kw)

2014-12-02 11:16:52-0500 [Controller 30434] File 鈥/usr/local/lib/python2.7/dist-packages/crossbar/controller/process.py鈥, line 547, in on_ready_error

2014-12-02 11:16:52-0500 [Controller 30434] raise ApplicationError(鈥渃rossbar.error.cannot_start鈥, emsg, worker.getlog())

2014-12-02 11:16:52-0500 [Controller 30434] ApplicationError: ApplicationError(鈥榗rossbar.error.cannot_start鈥, args = (鈥楨RROR: failed to start native worker - A process has ended with a probable error condition: process ended with exit code 1.鈥, []), kwargs = {})

2014-12-02 11:16:52-0500 [Controller 30434] Main loop terminated.


EOF

Concerning the versions, this is a development server and I can certainly install python and or libraries from source. However, I can鈥檛 make sweeping changes such as an OS upgrade. Ideally I need to make as few changes a necessary so as not to overburden the folks in charge of our configuration management system.

Regards,

Shannon

On Monday, December 1, 2014 1:17:41 PM UTC-5, Shannon Haworth wrote:

All,

I have installed crossbar successfully several times on Ubuntu based systems in the past. However, I am attempting to deploy crossbar onto a copy of a production server without success. I鈥檝e been working this problem for 4+ hours now. Hopefully someone will recognize this problem. :slight_smile:

I am new to python, however I do have 20+ years of UNIX experience.


OS details


hostname_redacted opt # lsb_release -a

No LSB modules are available.

Distributor ID: Ubuntu

Description: Ubuntu 12.04.5 LTS

Release: 12.04

Codename: precise


Check Python version


hostname_redacted opt # python --version

Python 2.7.3


Verify hosts entry


hostname_redacted opt # cat /etc/hosts

This host鈥檚 names (localhost)

127.0.0.1 localhost

This host

x.x.x.x hostname_redacted


Check crossbar versions


hostname_redacted opt # crossbar version

Crossbar.io package versions and platform information:

Crossbar.io : 0.9.11

Autobahn>Python : 0.9.3-3

WebSocket UTF8 Validator : wsaccel-0.6.2

WebSocket XOR Masker : wsaccel-0.6.2

WAMP JSON Codec : ujson-1.33

WAMP MsgPack Codec : msgpack-python-0.1.10

Twisted : 14.0.2-EPollReactor

Python : 2.7.3-CPython

OS : Linux-3.13.0-39-generic-x86_64-with-Ubuntu-12.04-precise

Machine : x86_64


Generate app


hostname_redacted opt # crossbar init --template hello:python --appdir crossbar_hello

Crossbar.io application directory 鈥榗rossbar_hello鈥 created

Initializing application template 鈥榟ello:python鈥 in directory 鈥/opt/crossbar_hello鈥

Using template from 鈥/usr/local/lib/python2.7/dist-packages/crossbar/templates/hello/python鈥

Creating directory /opt/crossbar_hello/.crossbar

Creating directory /opt/crossbar_hello/hello

Creating file /opt/crossbar_hello/MANIFEST.in

Creating file /opt/crossbar_hello/README.md

Creating file /opt/crossbar_hello/setup.py

Creating file /opt/crossbar_hello/.crossbar/config.json

Creating directory /opt/crossbar_hello/hello/web

Creating file /opt/crossbar_hello/hello/init.py

Creating file /opt/crossbar_hello/hello/hello.py

Creating file /opt/crossbar_hello/hello/web/autobahn.min.js

Creating file /opt/crossbar_hello/hello/web/index.html

Application template initialized

To start your node, run 鈥榗rossbar start --cbdir /opt/crossbar_hello/.crossbar鈥


Change port to 8888 (existing service on 8080)


hostname_redacted opt # sed -i -e 鈥渟/8080/8888/g鈥 crossbar_hello/.crossbar/config.json


Verify changes / show configuration


hostname_redacted opt # cat crossbar_hello/.crossbar/config.json

{

鈥渃ontroller鈥: {

},

鈥渨orkers鈥: [

{

鈥渢ype鈥: 鈥渞outer鈥,

鈥渙ptions鈥: {

鈥減ythonpath鈥: ["鈥"]

},

鈥渞ealms鈥: [

{

鈥渘ame鈥: 鈥渞ealm1鈥,

鈥渞oles鈥: [

{

鈥渘ame鈥: 鈥渁nonymous鈥,

鈥減ermissions鈥: [

{

鈥渦ri鈥: 鈥*鈥,

鈥減ublish鈥: true,

鈥渟ubscribe鈥: true,

鈥渃all鈥: true,

鈥渞egister鈥: true

}

]

}

]

}

],

鈥渢ransports鈥: [

{

鈥渢ype鈥: 鈥渨eb鈥,

鈥渆ndpoint鈥: {

鈥渢ype鈥: 鈥渢cp鈥,

鈥減ort鈥: 8888

},

鈥減aths鈥: {

鈥/鈥: {

鈥渢ype鈥: 鈥渟tatic鈥,

鈥渄irectory鈥: 鈥溾/hello/web鈥

},

鈥渨s鈥: {

鈥渢ype鈥: 鈥渨ebsocket鈥

}

}

}

]

},

{

鈥渢ype鈥: 鈥渃ontainer鈥,

鈥渙ptions鈥: {

鈥減ythonpath鈥: ["鈥"]

},

鈥渃omponents鈥: [

{

鈥渢ype鈥: 鈥渃lass鈥,

鈥渃lassname鈥: 鈥渉ello.hello.AppSession鈥,

鈥渞ealm鈥: 鈥渞ealm1鈥,

鈥渢ransport鈥: {

鈥渢ype鈥: 鈥渨ebsocket鈥,

鈥渆ndpoint鈥: {

鈥渢ype鈥: 鈥渢cp鈥,

鈥渉ost鈥: 鈥127.0.0.1鈥,

鈥減ort鈥: 8888

},

鈥渦rl鈥: 鈥渨s://127.0.0.1:8888/ws

}

}

]

}

]

}


Start crossbar


hostname_redacted opt # crossbar start --cbdir /opt/crossbar_hello/.crossbar

2014-12-01 13:00:32-0500 [Controller 14417] Log opened.

2014-12-01 13:00:32-0500 [Controller 14417] ============================== Crossbar.io ==============================

2014-12-01 13:00:32-0500 [Controller 14417] Crossbar.io 0.9.11 starting

2014-12-01 13:00:32-0500 [Controller 14417] Running on CPython using EPollReactor reactor

2014-12-01 13:00:32-0500 [Controller 14417] Starting from node directory /opt/crossbar_hello/.crossbar

2014-12-01 13:00:32-0500 [Controller 14417] Traceback (most recent call last):

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/bin/crossbar鈥, line 9, in

2014-12-01 13:00:32-0500 [Controller 14417] load_entry_point(鈥榗rossbar==0.9.11鈥, 鈥榗onsole_scripts鈥, 鈥榗rossbar鈥)()

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/crossbar/controller/cli.py鈥, line 410, in run

2014-12-01 13:00:32-0500 [Controller 14417] options.func(options)

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/crossbar/controller/cli.py鈥, line 223, in run_command_start

2014-12-01 13:00:32-0500 [Controller 14417] from crossbar.controller.node import Node

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/crossbar/controller/node.py鈥, line 43, in

2014-12-01 13:00:32-0500 [Controller 14417] from crossbar.controller.process import NodeControllerSession

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/crossbar/controller/process.py鈥, line 55, in

2014-12-01 13:00:32-0500 [Controller 14417] from crossbar.common.process import NativeProcessSession

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/crossbar/common/process.py鈥, line 68, in

2014-12-01 13:00:32-0500 [Controller 14417] from crossbar.twisted.endpoint import create_listening_port_from_config

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/crossbar/twisted/endpoint.py鈥, line 46, in

2014-12-01 13:00:32-0500 [Controller 14417] from crossbar.twisted.tlsctx import TlsServerContextFactory, \

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/crossbar/twisted/tlsctx.py鈥, line 23, in

2014-12-01 13:00:32-0500 [Controller 14417] from twisted.internet.ssl import DefaultOpenSSLContextFactory

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/twisted/internet/ssl.py鈥, line 223, in

2014-12-01 13:00:32-0500 [Controller 14417] from twisted.internet._sslverify import (

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/twisted/internet/_sslverify.py鈥, line 184, in

2014-12-01 13:00:32-0500 [Controller 14417] verifyHostname, VerificationError = _selectVerifyImplementation()

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/twisted/internet/_sslverify.py鈥, line 159, in _selectVerifyImplementation

2014-12-01 13:00:32-0500 [Controller 14417] from service_identity import VerificationError

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/service_identity/init.py鈥, line 12, in

2014-12-01 13:00:32-0500 [Controller 14417] from . import pyopenssl

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/service_identity/pyopenssl.py鈥, line 12, in

2014-12-01 13:00:32-0500 [Controller 14417] from pyasn1_modules.rfc2459 import GeneralNames

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/pyasn1_modules/rfc2459.py鈥, line 72, in

2014-12-01 13:00:32-0500 [Controller 14417] class AttributeValue(univ.Any): pass

2014-12-01 13:00:32-0500 [Controller 14417] AttributeError: 鈥榤odule鈥 object has no attribute 鈥楢ny鈥

EOF

Thank you for your time and assistance.

Shannon Haworth

0 Likes

#4

Shannon,

alright, we made some progress, but not completely:(

The container worker exits for some reasons with exit code 1. You might try to remove the worker of type "container" for a moment and check if the router alone starts. Just remove the respective section from the config.

Is this a stock Ubuntu 12.04 LTS x86-64? I can check that myself in a VM in office on friday ..

Anyway: pretty sure we get that working on a stock 12.04 with system Python. It's just that Crossbar.io has quite some pieces and relies on layers of code, and making that work in a broad set of environments sometimes requires tinkering ..

Cheers,
/Tobias

路路路

Am 02.12.2014 17:27, schrieb Shannon Haworth:

Tobias,

Thank you for your prompt reply. I really need to learn the Python
ecosystem.

Here are the results of your suggestion:

*#*pip install -U pyasn1

Downloading/unpacking pyasn1

聽聽聽Downloading pyasn1-0.1.7.tar.gz (68Kb): 68Kb downloaded

聽聽聽Running setup.py egg_info for package pyasn1

Installing collected packages: pyasn1

聽聽聽Found existing installation: pyasn1 0.0.11a

聽聽聽聽聽Uninstalling pyasn1:

聽聽聽聽聽聽聽Successfully uninstalled pyasn1

聽聽聽Running setup.py install for pyasn1

Successfully installed pyasn1

Cleaning up...

-------------

Followed by

-------------

*#*crossbar start --cbdir /opt/crossbar_hello/.crossbar

2014-12-02 11:16:37-0500 [Controller 30434] Log opened.

2014-12-02 11:16:37-0500 [Controller 30434]
============================== Crossbar.io ==============================

2014-12-02 11:16:37-0500 [Controller 30434] Crossbar.io 0.9.11 starting

2014-12-02 11:16:37-0500 [Controller 30434] Running on CPython using
EPollReactor reactor

2014-12-02 11:16:37-0500 [Controller 30434] Starting from node
directory /opt/crossbar_hello/.crossbar

2014-12-02 11:16:42-0500 [Controller 30434] Starting from local
configuration '/opt/crossbar_hello/.crossbar/config.json'

2014-12-02 11:16:42-0500 [Controller 30434] Warning: process utilities
not available

2014-12-02 11:16:42-0500 [Controller 30434] No WAMPlets detected in
enviroment.

2014-12-02 11:16:43-0500 [Controller 30434] Starting Router with ID
'worker1' ..

2014-12-02 11:16:43-0500 [Controller 30434] Entering reactor event loop ...

2014-12-02 11:16:43-0500 [Router 30437] Log opened.

2014-12-02 11:16:43-0500 [Router 30437] Running under CPython using
EPollReactor reactor

2014-12-02 11:16:49-0500 [Router 30437] Entering event loop ..

2014-12-02 11:16:49-0500 [Router 30437] Warning: process utilities
not available

2014-12-02 11:16:51-0500 [Router 30437] Connection to node
controller lost.

2014-12-02 11:16:51-0500 [Controller 30434] Worker 30437: Process
connection gone (A process has ended with a probable error condition:
process ended with exit code 1.)

2014-12-02 11:16:51-0500 [Controller 30434] ERROR: failed to start
native worker - A process has ended with a probable error condition:
process ended with exit code 1.

2014-12-02 11:16:51-0500 [Controller 30434] Traceback (most recent call
last):

2014-12-02 11:16:51-0500 [Controller 30434] File
"/usr/local/lib/python2.7/dist-packages/crossbar/controller/node.py",
line 187, in run_node_config

2014-12-02 11:16:51-0500 [Controller 30434] yield
self._run_node_config(config)

2014-12-02 11:16:51-0500 [Controller 30434] File
"/usr/local/lib/python2.7/dist-packages/twisted/internet/defer.py", line
1097, in _inlineCallbacks

2014-12-02 11:16:52-0500 [Controller 30434] result =
result.throwExceptionIntoGenerator(g)

2014-12-02 11:16:52-0500 [Controller 30434] File
"/usr/local/lib/python2.7/dist-packages/twisted/python/failure.py", line
389, in throwExceptionIntoGenerator

2014-12-02 11:16:52-0500 [Controller 30434] return
g.throw(self.type, self.value, self.tb)

2014-12-02 11:16:52-0500 [Controller 30434] File
"/usr/local/lib/python2.7/dist-packages/crossbar/controller/node.py",
line 257, in _run_node_config

2014-12-02 11:16:52-0500 [Controller 30434] yield
self._controller.start_router(worker_id, worker_options, details =
call_details)

2014-12-02 11:16:52-0500 [Controller 30434] File
"/usr/local/lib/python2.7/dist-packages/twisted/internet/defer.py", line
577, in _runCallbacks

2014-12-02 11:16:52-0500 [Controller 30434] current.result =
callback(current.result, *args, **kw)

2014-12-02 11:16:52-0500 [Controller 30434] File
"/usr/local/lib/python2.7/dist-packages/crossbar/controller/process.py",
line 547, in on_ready_error

2014-12-02 11:16:52-0500 [Controller 30434] raise
ApplicationError("crossbar.error.cannot_start", emsg, worker.getlog())

2014-12-02 11:16:52-0500 [Controller 30434] ApplicationError:
ApplicationError('crossbar.error.cannot_start', args = ('ERROR: failed
to start native worker - A process has ended with a probable error
condition: process ended with exit code 1.', []), kwargs = {})

2014-12-02 11:16:52-0500 [Controller 30434] Main loop terminated.

------------------

EOF

Concerning the versions, this is a development server and I can
certainly install python and or libraries from source. However, I can't
make sweeping changes such as an OS upgrade. Ideally I need to make as
few changes a necessary so as not to overburden the folks in charge of
our configuration management system.

Regards,

Shannon

On Monday, December 1, 2014 1:17:41 PM UTC-5, Shannon Haworth wrote:

聽聽聽聽All,

聽聽聽聽I have installed crossbar successfully several times on Ubuntu based
聽聽聽聽systems in the past. However, I am attempting to deploy crossbar
聽聽聽聽onto a copy of a production server without success. I've been
聽聽聽聽working this problem for 4+ hours now. Hopefully someone will
聽聽聽聽recognize this problem. :slight_smile:

聽聽聽聽I am new to python, however I do have 20+ years of UNIX experience.

聽聽聽聽------------------------------------------------------
聽聽聽聽OS details
聽聽聽聽------------------------------------------------------
聽聽聽聽hostname_redacted opt # lsb_release -a
聽聽聽聽No LSB modules are available.
聽聽聽聽Distributor ID:Ubuntu
聽聽聽聽Description:Ubuntu 12.04.5 LTS
聽聽聽聽Release:12.04
聽聽聽聽Codename:precise

聽聽聽聽------------------------------------------------------
聽聽聽聽Check Python version
聽聽聽聽------------------------------------------------------
聽聽聽聽hostname_redacted opt # python --version
聽聽聽聽Python 2.7.3

聽聽聽聽------------------------------------------------------
聽聽聽聽Verify hosts entry
聽聽聽聽------------------------------------------------------
聽聽聽聽hostname_redacted opt # cat /etc/hosts

聽聽聽聽# This host's names (localhost)
聽聽聽聽#
聽聽聽聽127.0.0.1localhost

聽聽聽聽# This host
聽聽聽聽x.x.x.xhostname_redacted

聽聽聽聽------------------------------------------------------
聽聽聽聽Check crossbar versions
聽聽聽聽------------------------------------------------------
聽聽聽聽hostname_redacted opt # crossbar version

聽聽聽聽Crossbar.io package versions and platform information:

聽聽聽聽Crossbar.io : 0.9.11

聽聽聽聽聽聽聽Autobahn>Python : 0.9.3-3
聽聽聽聽聽聽聽聽聽WebSocket UTF8 Validator : wsaccel-0.6.2
聽聽聽聽聽聽聽聽聽WebSocket XOR Masker : wsaccel-0.6.2
聽聽聽聽聽聽聽聽聽WAMP JSON Codec : ujson-1.33
聽聽聽聽聽聽聽聽聽WAMP MsgPack Codec : msgpack-python-0.1.10
聽聽聽聽聽聽聽Twisted : 14.0.2-EPollReactor
聽聽聽聽聽聽聽Python : 2.7.3-CPython

聽聽聽聽OS :
聽聽聽聽Linux-3.13.0-39-generic-x86_64-with-Ubuntu-12.04-precise
聽聽聽聽Machine : x86_64

聽聽聽聽------------------------------------------------------
聽聽聽聽Generate app
聽聽聽聽------------------------------------------------------
聽聽聽聽hostname_redacted opt # crossbar init --template hello:python
聽聽聽聽--appdir crossbar_hello
聽聽聽聽Crossbar.io application directory 'crossbar_hello' created
聽聽聽聽Initializing application template 'hello:python' in directory
聽聽聽聽'/opt/crossbar_hello'
聽聽聽聽Using template from
聽聽聽聽'/usr/local/lib/python2.7/dist-packages/crossbar/templates/hello/python'
聽聽聽聽Creating directory /opt/crossbar_hello/.crossbar
聽聽聽聽Creating directory /opt/crossbar_hello/hello
聽聽聽聽Creating file /opt/crossbar_hello/MANIFEST.in
聽聽聽聽Creating file /opt/crossbar_hello/README.md
聽聽聽聽Creating file /opt/crossbar_hello/setup.py
聽聽聽聽Creating file /opt/crossbar_hello/.crossbar/config.json
聽聽聽聽Creating directory /opt/crossbar_hello/hello/web
聽聽聽聽Creating file /opt/crossbar_hello/hello/__init__.py
聽聽聽聽Creating file /opt/crossbar_hello/hello/hello.py
聽聽聽聽Creating file /opt/crossbar_hello/hello/web/autobahn.min.js
聽聽聽聽Creating file /opt/crossbar_hello/hello/web/index.html
聽聽聽聽Application template initialized

聽聽聽聽To start your node, run 'crossbar start --cbdir
聽聽聽聽/opt/crossbar_hello/.crossbar'

聽聽聽聽------------------------------------------------------
聽聽聽聽Change port to 8888 (existing service on 8080)
聽聽聽聽------------------------------------------------------
聽聽聽聽hostname_redacted opt # sed -i -e "s/8080/8888/g"
聽聽聽聽crossbar_hello/.crossbar/config.json

聽聽聽聽------------------------------------------------------
聽聽聽聽Verify changes / show configuration
聽聽聽聽------------------------------------------------------
聽聽聽聽hostname_redacted opt # cat crossbar_hello/.crossbar/config.json

聽聽聽聽{
聽聽聽聽聽聽聽聽"controller": {
聽聽聽聽聽聽聽聽},
聽聽聽聽聽聽聽聽"workers": [
聽聽聽聽聽聽聽聽聽聽聽{
聽聽聽聽聽聽聽聽聽聽聽聽聽聽"type": "router",
聽聽聽聽聽聽聽聽聽聽聽聽聽聽"options": {
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽"pythonpath": [".."]
聽聽聽聽聽聽聽聽聽聽聽聽聽聽},
聽聽聽聽聽聽聽聽聽聽聽聽聽聽"realms": [
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽{
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽"name": "realm1",
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽"roles": [
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽{
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽"name": "anonymous",
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽"permissions": [
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽{
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽"uri": "*",
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽"publish": true,
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽"subscribe": true,
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽"call": true,
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽"register": true
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽}
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽]
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽}
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽]
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽}
聽聽聽聽聽聽聽聽聽聽聽聽聽聽],
聽聽聽聽聽聽聽聽聽聽聽聽聽聽"transports": [
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽{
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽"type": "web",
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽"endpoint": {
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽"type": "tcp",
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽"port": 8888
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽},
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽"paths": {
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽"/": {
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽"type": "static",
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽"directory": "../hello/web"
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽},
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽"ws": {
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽"type": "websocket"
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽}
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽}
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽}
聽聽聽聽聽聽聽聽聽聽聽聽聽聽]
聽聽聽聽聽聽聽聽聽聽聽},
聽聽聽聽聽聽聽聽聽聽聽{
聽聽聽聽聽聽聽聽聽聽聽聽聽聽"type": "container",
聽聽聽聽聽聽聽聽聽聽聽聽聽聽"options": {
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽"pythonpath": [".."]
聽聽聽聽聽聽聽聽聽聽聽聽聽聽},
聽聽聽聽聽聽聽聽聽聽聽聽聽聽"components": [
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽{
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽"type": "class",
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽"classname": "hello.hello.AppSession",
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽"realm": "realm1",
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽"transport": {
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽"type": "websocket",
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽"endpoint": {
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽"type": "tcp",
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽"host": "127.0.0.1",
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽"port": 8888
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽},
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽"url": "ws://127.0.0.1:8888/ws
聽聽聽聽<http://127.0.0.1:8888/ws>"
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽}
聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽聽}
聽聽聽聽聽聽聽聽聽聽聽聽聽聽]
聽聽聽聽聽聽聽聽聽聽聽}
聽聽聽聽聽聽聽聽]
聽聽聽聽}

聽聽聽聽------------------------------------------------------
聽聽聽聽Start crossbar
聽聽聽聽------------------------------------------------------
聽聽聽聽hostname_redacted opt # crossbar start --cbdir
聽聽聽聽/opt/crossbar_hello/.crossbar
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] Log opened.
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417]
聽聽聽聽============================== Crossbar.io
聽聽聽聽==============================
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] Crossbar.io 0.9.11 starting
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] Running on CPython
聽聽聽聽using EPollReactor reactor
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] Starting from node
聽聽聽聽directory /opt/crossbar_hello/.crossbar
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] Traceback (most recent
聽聽聽聽call last):
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] File
聽聽聽聽"/usr/local/bin/crossbar", line 9, in <module>
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417]
聽聽聽聽load_entry_point('crossbar==0.9.11', 'console_scripts', 'crossbar')()
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] File
聽聽聽聽"/usr/local/lib/python2.7/dist-packages/crossbar/controller/cli.py",
聽聽聽聽line 410, in run
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] options.func(options)
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] File
聽聽聽聽"/usr/local/lib/python2.7/dist-packages/crossbar/controller/cli.py",
聽聽聽聽line 223, in run_command_start
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] from
聽聽聽聽crossbar.controller.node import Node
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] File
聽聽聽聽"/usr/local/lib/python2.7/dist-packages/crossbar/controller/node.py", line
聽聽聽聽43, in <module>
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] from
聽聽聽聽crossbar.controller.process import NodeControllerSession
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] File
聽聽聽聽"/usr/local/lib/python2.7/dist-packages/crossbar/controller/process.py",
聽聽聽聽line 55, in <module>
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] from
聽聽聽聽crossbar.common.process import NativeProcessSession
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] File
聽聽聽聽"/usr/local/lib/python2.7/dist-packages/crossbar/common/process.py",
聽聽聽聽line 68, in <module>
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] from
聽聽聽聽crossbar.twisted.endpoint import create_listening_port_from_config
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] File
聽聽聽聽"/usr/local/lib/python2.7/dist-packages/crossbar/twisted/endpoint.py",
聽聽聽聽line 46, in <module>
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] from
聽聽聽聽crossbar.twisted.tlsctx import TlsServerContextFactory, \
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] File
聽聽聽聽"/usr/local/lib/python2.7/dist-packages/crossbar/twisted/tlsctx.py",
聽聽聽聽line 23, in <module>
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] from
聽聽聽聽twisted.internet.ssl import DefaultOpenSSLContextFactory
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] File
聽聽聽聽"/usr/local/lib/python2.7/dist-packages/twisted/internet/ssl.py",
聽聽聽聽line 223, in <module>
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] from
聽聽聽聽twisted.internet._sslverify import (
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] File
聽聽聽聽"/usr/local/lib/python2.7/dist-packages/twisted/internet/_sslverify.py",
聽聽聽聽line 184, in <module>
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] verifyHostname,
聽聽聽聽VerificationError = _selectVerifyImplementation()
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] File
聽聽聽聽"/usr/local/lib/python2.7/dist-packages/twisted/internet/_sslverify.py",
聽聽聽聽line 159, in _selectVerifyImplementation
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] from
聽聽聽聽service_identity import VerificationError
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] File
聽聽聽聽"/usr/local/lib/python2.7/dist-packages/service_identity/__init__.py",
聽聽聽聽line 12, in <module>
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] from . import pyopenssl
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] File
聽聽聽聽"/usr/local/lib/python2.7/dist-packages/service_identity/pyopenssl.py",
聽聽聽聽line 12, in <module>
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] from
聽聽聽聽pyasn1_modules.rfc2459 import GeneralNames
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] File
聽聽聽聽"/usr/local/lib/python2.7/dist-packages/pyasn1_modules/rfc2459.py",
聽聽聽聽line 72, in <module>
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] class
聽聽聽聽AttributeValue(univ.Any): pass
聽聽聽聽2014-12-01 13:00:32-0500 [Controller 14417] AttributeError:
聽聽聽聽'module' object has no attribute 'Any'

聽聽聽聽EOF

聽聽聽聽Thank you for your time and assistance.

聽聽聽聽Shannon Haworth

--
You received this message because you are subscribed to the Google
Groups "Autobahn" group.
To unsubscribe from this group and stop receiving emails from it, send
an email to autobahnws+...@googlegroups.com
<mailto:autobahnws+...@googlegroups.com>.
To post to this group, send email to autob...@googlegroups.com
<mailto:autob...@googlegroups.com>.
To view this discussion on the web visit
https://groups.google.com/d/msgid/autobahnws/63ef3d06-d9d1-4a9b-abe3-72d24de6b8c0%40googlegroups.com
<https://groups.google.com/d/msgid/autobahnws/63ef3d06-d9d1-4a9b-abe3-72d24de6b8c0%40googlegroups.com?utm_medium=email&utm_source=footer>.
For more options, visit https://groups.google.com/d/optout.

0 Likes

#5

Good news, crossbar is working.

I wish this was a stock 12.04, our systems team has optimized the environment for a J2EE stack I鈥檓 afraid. Perfectly reasonable given the purpose of the server, however it does complicate my life a bit.

  • I compiled Python 2.7.8 from source and installed it to (/opt/python278)
  • grabbed pip (wget https://bootstrap.pypa.io/get-pip.py)
  • executed pip (/opt/python278/bin/python get-pip.py)
  • installed crossbar (/opt/python278/bin/pip install crossbar)
  • checked the version (/opt/python278/bin/crossbar version)
  • generated an app (crossbar init --template default --appdir /opt/crossbar/default_app)
  • Adjusted the port for my system
  • started crossbar (/opt/python278/bin/crossbar start --cbdir /opt/crossbar/default_app/.crossbar)
    This proved to be a clean solution that neatly bypasses any existing/legacy python. It should work on most Linux systems.

Thanks again for pointing out the root concerns.

Shannon

路路路

On Monday, December 1, 2014 1:17:41 PM UTC-5, Shannon Haworth wrote:

All,

I have installed crossbar successfully several times on Ubuntu based systems in the past. However, I am attempting to deploy crossbar onto a copy of a production server without success. I鈥檝e been working this problem for 4+ hours now. Hopefully someone will recognize this problem. :slight_smile:

I am new to python, however I do have 20+ years of UNIX experience.


OS details


hostname_redacted opt # lsb_release -a

No LSB modules are available.

Distributor ID: Ubuntu

Description: Ubuntu 12.04.5 LTS

Release: 12.04

Codename: precise


Check Python version


hostname_redacted opt # python --version

Python 2.7.3


Verify hosts entry


hostname_redacted opt # cat /etc/hosts

This host鈥檚 names (localhost)

127.0.0.1 localhost

This host

x.x.x.x hostname_redacted


Check crossbar versions


hostname_redacted opt # crossbar version

Crossbar.io package versions and platform information:

Crossbar.io : 0.9.11

Autobahn>Python : 0.9.3-3

WebSocket UTF8 Validator : wsaccel-0.6.2

WebSocket XOR Masker : wsaccel-0.6.2

WAMP JSON Codec : ujson-1.33

WAMP MsgPack Codec : msgpack-python-0.1.10

Twisted : 14.0.2-EPollReactor

Python : 2.7.3-CPython

OS : Linux-3.13.0-39-generic-x86_64-with-Ubuntu-12.04-precise

Machine : x86_64


Generate app


hostname_redacted opt # crossbar init --template hello:python --appdir crossbar_hello

Crossbar.io application directory 鈥榗rossbar_hello鈥 created

Initializing application template 鈥榟ello:python鈥 in directory 鈥/opt/crossbar_hello鈥

Using template from 鈥/usr/local/lib/python2.7/dist-packages/crossbar/templates/hello/python鈥

Creating directory /opt/crossbar_hello/.crossbar

Creating directory /opt/crossbar_hello/hello

Creating file /opt/crossbar_hello/MANIFEST.in

Creating file /opt/crossbar_hello/README.md

Creating file /opt/crossbar_hello/setup.py

Creating file /opt/crossbar_hello/.crossbar/config.json

Creating directory /opt/crossbar_hello/hello/web

Creating file /opt/crossbar_hello/hello/init.py

Creating file /opt/crossbar_hello/hello/hello.py

Creating file /opt/crossbar_hello/hello/web/autobahn.min.js

Creating file /opt/crossbar_hello/hello/web/index.html

Application template initialized

To start your node, run 鈥榗rossbar start --cbdir /opt/crossbar_hello/.crossbar鈥


Change port to 8888 (existing service on 8080)


hostname_redacted opt # sed -i -e 鈥渟/8080/8888/g鈥 crossbar_hello/.crossbar/config.json


Verify changes / show configuration


hostname_redacted opt # cat crossbar_hello/.crossbar/config.json

{

鈥渃ontroller鈥: {

},

鈥渨orkers鈥: [

{

鈥渢ype鈥: 鈥渞outer鈥,

鈥渙ptions鈥: {

鈥減ythonpath鈥: ["鈥"]

},

鈥渞ealms鈥: [

{

鈥渘ame鈥: 鈥渞ealm1鈥,

鈥渞oles鈥: [

{

鈥渘ame鈥: 鈥渁nonymous鈥,

鈥減ermissions鈥: [

{

鈥渦ri鈥: 鈥*鈥,

鈥減ublish鈥: true,

鈥渟ubscribe鈥: true,

鈥渃all鈥: true,

鈥渞egister鈥: true

}

]

}

]

}

],

鈥渢ransports鈥: [

{

鈥渢ype鈥: 鈥渨eb鈥,

鈥渆ndpoint鈥: {

鈥渢ype鈥: 鈥渢cp鈥,

鈥減ort鈥: 8888

},

鈥減aths鈥: {

鈥/鈥: {

鈥渢ype鈥: 鈥渟tatic鈥,

鈥渄irectory鈥: 鈥溾/hello/web鈥

},

鈥渨s鈥: {

鈥渢ype鈥: 鈥渨ebsocket鈥

}

}

}

]

},

{

鈥渢ype鈥: 鈥渃ontainer鈥,

鈥渙ptions鈥: {

鈥減ythonpath鈥: ["鈥"]

},

鈥渃omponents鈥: [

{

鈥渢ype鈥: 鈥渃lass鈥,

鈥渃lassname鈥: 鈥渉ello.hello.AppSession鈥,

鈥渞ealm鈥: 鈥渞ealm1鈥,

鈥渢ransport鈥: {

鈥渢ype鈥: 鈥渨ebsocket鈥,

鈥渆ndpoint鈥: {

鈥渢ype鈥: 鈥渢cp鈥,

鈥渉ost鈥: 鈥127.0.0.1鈥,

鈥減ort鈥: 8888

},

鈥渦rl鈥: 鈥渨s://127.0.0.1:8888/ws

}

}

]

}

]

}


Start crossbar


hostname_redacted opt # crossbar start --cbdir /opt/crossbar_hello/.crossbar

2014-12-01 13:00:32-0500 [Controller 14417] Log opened.

2014-12-01 13:00:32-0500 [Controller 14417] ============================== Crossbar.io ==============================

2014-12-01 13:00:32-0500 [Controller 14417] Crossbar.io 0.9.11 starting

2014-12-01 13:00:32-0500 [Controller 14417] Running on CPython using EPollReactor reactor

2014-12-01 13:00:32-0500 [Controller 14417] Starting from node directory /opt/crossbar_hello/.crossbar

2014-12-01 13:00:32-0500 [Controller 14417] Traceback (most recent call last):

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/bin/crossbar鈥, line 9, in

2014-12-01 13:00:32-0500 [Controller 14417] load_entry_point(鈥榗rossbar==0.9.11鈥, 鈥榗onsole_scripts鈥, 鈥榗rossbar鈥)()

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/crossbar/controller/cli.py鈥, line 410, in run

2014-12-01 13:00:32-0500 [Controller 14417] options.func(options)

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/crossbar/controller/cli.py鈥, line 223, in run_command_start

2014-12-01 13:00:32-0500 [Controller 14417] from crossbar.controller.node import Node

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/crossbar/controller/node.py鈥, line 43, in

2014-12-01 13:00:32-0500 [Controller 14417] from crossbar.controller.process import NodeControllerSession

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/crossbar/controller/process.py鈥, line 55, in

2014-12-01 13:00:32-0500 [Controller 14417] from crossbar.common.process import NativeProcessSession

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/crossbar/common/process.py鈥, line 68, in

2014-12-01 13:00:32-0500 [Controller 14417] from crossbar.twisted.endpoint import create_listening_port_from_config

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/crossbar/twisted/endpoint.py鈥, line 46, in

2014-12-01 13:00:32-0500 [Controller 14417] from crossbar.twisted.tlsctx import TlsServerContextFactory, \

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/crossbar/twisted/tlsctx.py鈥, line 23, in

2014-12-01 13:00:32-0500 [Controller 14417] from twisted.internet.ssl import DefaultOpenSSLContextFactory

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/twisted/internet/ssl.py鈥, line 223, in

2014-12-01 13:00:32-0500 [Controller 14417] from twisted.internet._sslverify import (

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/twisted/internet/_sslverify.py鈥, line 184, in

2014-12-01 13:00:32-0500 [Controller 14417] verifyHostname, VerificationError = _selectVerifyImplementation()

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/twisted/internet/_sslverify.py鈥, line 159, in _selectVerifyImplementation

2014-12-01 13:00:32-0500 [Controller 14417] from service_identity import VerificationError

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/service_identity/init.py鈥, line 12, in

2014-12-01 13:00:32-0500 [Controller 14417] from . import pyopenssl

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/service_identity/pyopenssl.py鈥, line 12, in

2014-12-01 13:00:32-0500 [Controller 14417] from pyasn1_modules.rfc2459 import GeneralNames

2014-12-01 13:00:32-0500 [Controller 14417] File 鈥/usr/local/lib/python2.7/dist-packages/pyasn1_modules/rfc2459.py鈥, line 72, in

2014-12-01 13:00:32-0500 [Controller 14417] class AttributeValue(univ.Any): pass

2014-12-01 13:00:32-0500 [Controller 14417] AttributeError: 鈥榤odule鈥 object has no attribute 鈥楢ny鈥

EOF

Thank you for your time and assistance.

Shannon Haworth

0 Likes

#6

Shannon,

Good news, crossbar is working.

That's good to hear!

I wish this was a stock 12.04, our systems team has optimized the
environment for a J2EE stack I'm afraid. Perfectly reasonable given the
purpose of the server, however it does complicate my life a bit.

... Crossbar/Python from source installation ...

This proved to be a clean solution that neatly bypasses any
existing/legacy python. It should work on most Linux systems.

Running Crossbar.io on a Python completely built from stock sources is actually the best approach overall!

This is what we do regularily, also for production. We deliberately don't rely on system Python packages. This removes a source of issues and you can always use the latest Python without waiting for distros and without interferring with system Python other stuff might rely upon.
And building CPython from sources is a snap nowerdays.

Cheers,
/Tobias

路路路

Am 03.12.2014 04:11, schrieb Shannon Haworth:

0 Likes