Ask Your Question

notebok server on ubuntu

asked 2014-10-16 18:35:00 +0200

czsan gravatar image

On ubuntu (versions from 12.04 to 14.04) I got the following error, when I started the notebook server with secure=True parameter:

RuntimeError Traceback (most recent call last) <ipython-input-3-3d6cf59ae321> in <module>() ----> 1 notebook(secure=True)

/usr/lib/sagemath/local/lib/python2.7/site-packages/sage/misc/ in sage.misc.lazy_import.LazyImport.__call__ (build/cythonized/sage/misc/lazy_import.c:3000)()

/usr/lib/sagemath/local/lib/python2.7/site-packages/sagenb- in __call__(self, args, *kwds) 226 """ 227 def __call__(self, args, *kwds): --> 228 return self.notebook(args, *kwds) 229 230 notebook = run_notebook.notebook_run

/usr/lib/sagemath/local/lib/python2.7/site-packages/sagenb- in notebook_run(self, directory, port, interface, port_tries, secure, reset, accounts, openid, server_pool, ulimit, timeout, doc_timeout, upload, automatic_login, start_path, fork, quiet, server, profile, subnets, require_login, open_viewer, address) 475 import OpenSSL 476 except ImportError: --> 477 raise RuntimeError("HTTPS cannot be used without pyOpenSSL" 478 " installed. See the Sage README for more information.") 479

RuntimeError: HTTPS cannot be used without pyOpenSSL installed. See the Sage README for more information.

SOme remarks: First: this server was a live ~6.1* server using secure=True parameter (we used it over https). After some updating of ubuntu it crashed. Second: Since this accident I tried some new versions of Ubuntu and later versions of Sage, but the error remain same. Third: otherwise the program runs - yet the notebook server too (without SSL)

edit retag flag offensive close merge delete


do you have Sage packages openssl and pyopenssl installed?

Dima gravatar imageDima ( 2014-10-16 22:44:47 +0200 )edit

Yes, they are installed. I found, that this is not ubuntu problem, the effect is same on arch linux.

czsan gravatar imageczsan ( 2014-10-16 23:34:00 +0200 )edit

Do you have certtool installed (on debian it's in the package gnutls-bin)? I tried doing notebook(secure=True) on my system, and it complained about absence of certtool. After installing it it worked.

Dima gravatar imageDima ( 2014-10-17 10:58:33 +0200 )edit

1 Answer

Sort by ยป oldest newest most voted

answered 2014-10-17 11:01:28 +0200

Check that you have Sage packages openssl and pyopenssl installed, as well as the certtool (on debian it's in gnutls-bin (deb) package).

It might be that the old SSL certificates for sagenb server you have from previous versions need to be removed.

edit flag offensive delete link more


I think it is not true; I newly installed arch linux on two machine (Antergos distro), the problem is same.

czsan gravatar imageczsan ( 2014-11-05 12:45:59 +0200 )edit

What is not true? That it's not about old SSL certs? OK, how about the packages I mentioned?

Dima gravatar imageDima ( 2014-11-10 22:23:25 +0200 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower


Asked: 2014-10-16 18:35:00 +0200

Seen: 874 times

Last updated: Oct 17 '14