Jupyter Notebook 开启远程登录

Jupyter Notebook可以说是非常好用的小工具,但是不经过配置只能够在本机访问

安装jupyter notebook

conda install jupyter notebook

生成默认配置文件

jupyter notebook --generate-config

将会在用户主目录下生成.jupyter文件夹,其中jupyter_notebook_config.py就是刚刚生成的配置文件

配置访问密码

bash 复制代码
jupyter notebook password #设置 jupyter 的密码,并生成自己配置文件,目录在 ~/.jupyter/jupyter_notebook_config.py test123456

修改配置文件

修改用户主目录下~/.jupyter/jupyter_notebook_config.py文件

text 复制代码
c.NotebookApp.ip='*'
c.NotebookApp.open_browser = False
c.NotebookApp.port=8888

测试

在服务器开启jupyter notebook

  • 浏览器不会自动开启
  • 其他电脑在浏览器输入服务器ip:8888,能够访问jupyter notebook

jupyter notebook

有如下提示

在笔记本浏览器输入外网ip:8888

成功远程访问服务器的jupyter notebook
输入设置的密码即可进入

后台启动

nohup jupyter notebook --allow-root > /root/nohup.log &

相关推荐
June bug39 分钟前
【Python基础】变量、运算与内存管理全解析
开发语言·python·职场和发展·测试
蹦蹦跳跳真可爱5891 小时前
Python----OpenCV(几何变换--图像平移、图像旋转、放射变换、图像缩放、透视变换)
开发语言·人工智能·python·opencv·计算机视觉
蹦蹦跳跳真可爱5891 小时前
Python----循环神经网络(Transformer ----Layer-Normalization(层归一化))
人工智能·python·rnn·transformer
m0_625686551 小时前
Day58
python
夜阳朔1 小时前
Conda环境激活失效问题
人工智能·后端·python
m0_723140231 小时前
Python训练营-Day49
开发语言·python
北风toto2 小时前
python学习DataFrame数据结构
数据结构·python·学习
亿牛云爬虫专家2 小时前
微服务化采集平台:可扩展性与容错机制
python·微服务·架构·爬虫代理·扩展性·新浪财经·财经新闻
傻啦嘿哟2 小时前
Python爬虫动态IP代理报错全解析:从问题定位到实战优化
爬虫·python·tcp/ip
mit6.8242 小时前
[Meetily后端框架] Whisper转录服务器 | 后端服务管理脚本
c++·人工智能·后端·python