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 &

相关推荐
多打代码18 小时前
2026.02.11
开发语言·python
AI周红伟19 小时前
周红伟:智能体实战,通过使用 Flask 的 REST API 在 Python 中部署 PyTorch
后端·python·flask
清水白石00819 小时前
Python 性能分析实战指南:timeit、cProfile、line_profiler 从入门到精通
开发语言·python
ValhallaCoder19 小时前
hot100-二分查找
数据结构·python·算法·二分查找
Suryxin.19 小时前
从0开始复现nano-vllm「llm_engine.py」
人工智能·python·深度学习·ai·vllm
PieroPc19 小时前
用python 写的 Gitee 数据备份工具
开发语言·python·gitee
电饭叔19 小时前
intVar 说明
python
癫狂的兔子19 小时前
【Python】【机器学习】十大算法简介与应用
python·算法·机器学习
ZaneAI19 小时前
🚀 Claude Agent SDK 使用指南:概述
python·agent·claude
闻哥20 小时前
Java虚拟机内存结构深度解析:从底层原理到实战调优
java·开发语言·jvm·python·面试·springboot