首页 > 解决方案 > 如何更改 Azure DSVM 虚拟机上的默认启动文件夹 jupyter hub

问题描述

Azure DSVM 在端口 8000 上启用了 jupyterlab。但是,jupyterlab 中的启动文件夹始终从 /home/*user-name/notbook 开始。我想更改 jupyterlab 启动文件夹,但我不知道该怎么做。

试过了

1.

我通过参考stackoverflow创建了一个 jupyterlab 配置来更改c.NotebookApp.notbook_dir,但重新启动并再次检查服务器操作。我已经确认它不起作用。

2.

我也尝试创建一个jupyterhub配置,但结果是没有名为jupyterhub的命令。我以为它在docker中工作,但是docker中没有jupyterhub的进程。

3.

网络统计-tnlp

Proto Recv-Q Send-Q Local Address           Foreign Address         State       PID/Program name    
tcp        0      0 0.0.0.0:111             0.0.0.0:*               LISTEN      -                   
tcp        0      0 127.0.0.1:8081          0.0.0.0:*               LISTEN      -                   
tcp        0      0 127.0.0.53:53           0.0.0.0:*               LISTEN      -                   
tcp        0      0 0.0.0.0:22              0.0.0.0:*               LISTEN      -                   
tcp        0      0 127.0.0.1:8001          0.0.0.0:*               LISTEN      -                   
tcp        0      0 127.0.0.1:44675         0.0.0.0:*               LISTEN      -                   
tcp        0      0 127.0.0.1:46277         0.0.0.0:*               LISTEN      2048/python         
tcp6       0      0 :::111                  :::*                    LISTEN      -                   
tcp6       0      0 :::22                   :::*                    LISTEN      -                   
tcp6       0      0 :::8000                 :::*                    LISTEN      -              

ps辅助| grep jupyter

root      1345  0.0  0.0  13316  3304 ?        Ss   00:06   0:00 /bin/bash /etc/jupyterhub/start_jupyterhub.sh
root      1624  0.0  0.0 246340 64268 ?        Sl   00:06   0:01 /anaconda/bin/python /anaconda/bin/jupyterhub --log-file=/var/log/jupyterhub.log
root      1949  0.0  0.0 606436 51356 ?        Ssl  00:06   0:01 node /usr/local/bin/configurable-http-proxy --ip * --port 8000 --api-ip 127.0.0.1 --api-port 8001 --error-target http://127.0.0.1:8081/hub/error --ssl-key /etc/jupyterhub/srv/server.key --ssl-cert /etc/jupyterhub/srv/server.crt
rootadm+  2048  0.2  0.0 343804 101160 ?       Ssl  00:07   0:03 /anaconda/bin/python /anaconda/bin/jupyterhub-singleuser --port=46277 --notebook-dir=~/notebooks --SingleUserNotebookApp.default_url=/lab --config=/etc/jupyterhub/default_jupyter_config.py
rootadm+  3841  0.0  0.0  14864  1040 pts/0    S+   00:27   0:00 grep --color=auto jupyter

标签: azurejupyterjupyter-labjupyterhubazure-dsvm

解决方案


推荐阅读