0

I am trying to run jupyterhub for multiuser mode:

sudo jupyterhub

I am able to login successfully with the user I used to install jupyterhub. However, when I try to login with other users I get the following message:

500: Internal Server Error Spawner failed to start [status=1]

And in the terminal:

user@server:~$ sudo jupyterhub

[I 2017-02-18 11:47:53.663 JupyterHub app:733] Loading cookie_secret from /home/user/jupyterhub_cookie_secret

[W 2017-02-18 11:47:53.691 JupyterHub app:372] Generating CONFIGPROXY_AUTH_TOKEN. Restarting the Hub will require restarting the proxy. Set CONFIGPROXY_AUTH_TOKEN env or JupyterHub.proxy_auth_token config to avoid this message.

[W 2017-02-18 11:47:53.695 JupyterHub app:874] No admin users, admin interface will be unavailable.

[W 2017-02-18 11:47:53.695 JupyterHub app:875] Add any administrative users to c.Authenticator.admin_users in config.

[I 2017-02-18 11:47:53.695 JupyterHub app:902] Not using whitelist. Any authenticated user will be allowed.

[I 2017-02-18 11:47:53.714 JupyterHub app:1481] Hub API listening on http://127.0.0.1:8081/hub/

[W 2017-02-18 11:47:53.716 JupyterHub app:1201] Running JupyterHub without SSL. I hope there is SSL termination happening somewhere else...

[I 2017-02-18 11:47:53.716 JupyterHub app:1203] Starting proxy @ http://*:8000/

11:47:54.569 - info: [ConfigProxy] Proxying http://*:8000 to http://127.0.0.1:8081

11:47:54.574 - info: [ConfigProxy] Proxy API at http://127.0.0.1:8001/api/routes

[I 2017-02-18 11:47:54.597 JupyterHub app:1537] JupyterHub is now running at http://127.0.0.1:8000/

Last login: Sat Feb 18 00:26:34 CET 2017

Welcome to Ubuntu 16.04.2 LTS (GNU/Linux 4.4.0-62-generic x86_64)

1 package can be updated.

0 updates are security updates.

[I 2017-02-18 11:48:10.990 JupyterHub spawner:785] Spawning jupyterhub-singleuser '--user="username"' '--cookie-name="jupyter-hub-token-username"' '--base-url="/user/username"' '--hub-host=""' '--hub-prefix="/hub/"' '--hub-api-url="http://127.0.0.1:8081/hub/api"' '--ip="127.0.0.1"' --port=52764

Traceback (most recent call last):

File "/usr/local/bin/jupyterhub-singleuser", line 4, in import('pkg_resources').require('jupyterhub==0.8.0.dev0') File

"/usr/local/lib/python3.5/dist-packages/pkg_resources/init.py", line 3036, in @_call_aside

File "/usr/local/lib/python3.5/dist-packages/pkg_resources/init.py", line 3020, in _call_aside f(*args, **kwargs)

File "/usr/local/lib/python3.5/dist-packages/pkg_resources/init.py", line 3049, in _initialize_master_working_set working_set = WorkingSet._build_master()

File "/usr/local/lib/python3.5/dist-packages/pkg_resources/init.py", line 654, in _build_master ws.require(requires)

File "/usr/local/lib/python3.5/dist-packages/pkg_resources/init.py", line 968, in require needed = self.resolve(parse_requirements(requirements))

File "/usr/local/lib/python3.5/dist-packages/pkg_resources/init.py", line 854, in resolve raise DistributionNotFound(req, requirers)

pkg_resources.DistributionNotFound: The 'jupyterhub==0.8.0.dev0' distribution was not found and is required by the application

[W 2017-02-18 11:48:21.038 JupyterHub web:1545] 500 POST /hub/login?next= (::ffff:10.90.0.4): Spawner failed to start [status=1]

[E 2017-02-18 11:48:21.066 JupyterHub log:99] {

"Content-Length": "36",

"Content-Type": "application/x-www-form-urlencoded",

"Accept-Encoding": "gzip, deflate",

"Accept-Language": "en-US",

"Dnt": "1",

"Host": "zeno.lehre.hwr-berlin.de:8000",

"Cookie": "_xsrf=2|1204c4dd|f391c8200e87548242350a9d25406790|1487111102",

"X-Forwarded-Host": "server.com:8000",

"Connection": "close",

"X-Forwarded-For": "::ffff:...",

"X-Forwarded-Proto": "http",

"Accept": "text/html, application/xhtml+xml, /",

"Cache-Control": "no-cache",

"User-Agent": "Mozilla/5.0 (Windows NT 6.1; WOW64; Trident/7.0; rv:11.0) like Gecko",

"Referer": "http://server.com:8000/hub/login",

"X-Forwarded-Port": "8000"

}

[E 2017-02-18 11:48:21.066 JupyterHub log:100] 500 POST /hub/login?next= (@::ffff:...) 10283.44ms

I don't know if that would be the source of the problem, however, I have jupyterhub version: 0.7.0. I tried to update it to 0.8.0 using:

sudo pip install -U jupyterhub

But, I got:

Requirement already up-to-date: ****

I tried so long to find a solution online; I failed though.

Would someone please help me with this issue?

Thanks :)

4

1 回答 1

2

你可能会从源代码安装 jupyterhub 并看到这个日志:</p>

“pkg_resources.DistributionNotFound: 'jupyterhub==0.8.0.dev0' 分发未找到,应用程序需要”

我遇到了同样的问题......这是由安装二进制 jupyterhub 并且不安装包引起的......在 exec 之后

pip3 install -r dev-requiremetns.txt .

日志让我们通过“为jupyterhub运行setup.py开发”来执行setup.py,然后运行python setup.py build然后python setup.py install中止,日志让我使用pip install .然后运行 pip3 install .,然后jupyterhub正常运行。

以下命令:

cd /path to git code/jupyterhub/
python setup.py build
python setup.py install
pip3 install .
于 2017-06-14T06:55:11.083 回答