Jupyterhub cannot start server - 500 error

不问归期 提交于 2019-12-12 04:10:39

问题


I am trying to run jupyter hub for multiuser mode. I installed jupyterhub from PIP.

[root@ip-of-machine hadoop]# echo $PATH

/usr/local/bin/jupyterhub-singleuser:/usr/local/bin/jupyterhub:/sbin:/bin:/usr/sbin:/usr/bin:/opt/aws/bin

When I tun jupyterhub I get an error saying

500 : Internal Server Error

Failed to start your server. Please contact admin.

I ran it as

[root@ip-of-machine hadoop]# /usr/local/bin/jupyterhub -f ./jupyterhub/jupyterhub_config.py --no-ssl

The logs contain

[I 2016-05-03 17:13:09.406 JupyterHub spawner:465] Spawning jupyterhub-singleuser --user=jupyter --port=40770 --cookie-name=jupyter-hub-token-jupyter --base-url=/user/jupyter --hub-host= --hub-prefix=/hub/ --hub-api-url=http://127.0.0.1:8081/hub/api --ip=127.0.0.1
[E 2016-05-03 17:13:09.433 JupyterHub user:237] Unhandled error starting jupyter's server: [Errno 2] No such file or directory: 'jupyterhub-singleuser'

But there is singleuser in path. I explicitly added it to path and exported.

Any clues? Thanks.


回答1:


PATH should contain a list of directories containing executables that should be found, not the executables themselves.

So instead of

/usr/local/bin/jupyterhub-singleuser:/usr/local/bin/jupyterhub:/sbin:/bin:/usr/sbin:/usr/bin:/opt/aws/bin

your PATH should be:

/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/opt/aws/bin

which should find both jupyterhub and jupyterhub-singleuser.



来源:https://stackoverflow.com/questions/37010454/jupyterhub-cannot-start-server-500-error

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!