服务器登陆jupyer notebook失败

在服务器上启动jupter notebook,复制网站和token,发现网页打不开。原因是防火墙没有开放该端口(例如8888)

└──╼ jupyter notebook --ip 0.0.0.0
[I 09:13:36.965 NotebookApp] Writing notebook server cookie secret to /run/user/1000/jupyter/notebook_cookie_secret
[I 09:13:37.081 NotebookApp] Serving notebooks from local directory: /data/05.seqdata/08.APUS5/SEQ_201807
[I 09:13:37.081 NotebookApp] 0 active kernels
[I 09:13:37.081 NotebookApp] The Jupyter Notebook is running at: http://0.0.0.0:8888/?token=82377c20c3deba79e32d1831209ede7afac0e103e998f18c
[I 09:13:37.081 NotebookApp] Use Control-C to stop this server and shut down all kernels (twice to skip confirmation).
[W 09:13:37.081 NotebookApp] No web browser found: could not locate runnable browser.
[C 09:13:37.082 NotebookApp]

    Copy/paste this URL into your browser when you connect for the first time,
    to login with a token:
        http://0.0.0.0:8888/?token=82377c20c3deba79e32d1831209ede7afac0e103e998f18c

退出jupyter notebook , 防火墙开放目标端口, 然后再启动jupyter notebook

sudo su
systemctl status firewalld                                  #查看firewalld状态
systemctl start firewalld                                   #若没开启,则开启防火墙,没有任何提示即开启成功。
firewall-cmd --zone=public --add-port=8888/tcp --permanent  #开放端口8888
firewall-cmd --reload                                       #重置 
firewall-cmd --list-ports                                   #查看目前开放端口列表
exit

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值