Linux上部署Jupyter notebook

ops/2024/9/24 10:14:48/

jupyter_notebook_0">安装jupyter notebook

pip install notebook 
#或者
conda install notebook

配置

jupyter notebook --generate-config
## The IP address the notebook server will listen on.
#  Default: 'localhost'
# 设置可以访问的ip, 默认是localhost, 将其改为 '*'
c.NotebookApp.ip = '*'## The directory to use for notebooks and kernels.
#  Default: ''
# 默认打开目录
c.NotebookApp.notebook_dir = '/home/data123share66/python'## Whether to open in a browser after starting.
#                          The specific browser used is platform dependent and
#                          determined by the python standard library `webbrowser`
#                          module, unless it is overridden using the --browser
#                          (NotebookApp.browser) configuration option.
#  Default: True
# Jupyter notebook启动后是否打开浏览器, 设为 False 即可
c.NotebookApp.open_browser = False## Hashed password to use for web authentication.
#  
#                        To generate, type in a python/IPython shell:
#  
#                          from notebook.auth import passwd; passwd()
#  
#                        The string should be of the form type:salt:hashed-
#  password.
#  Default: ''
c.NotebookApp.password = 'argon2:$argon2id$v=19$m=10240,t=10,p=8$Ny6WDdoLBm88cUMyOqgNqg$s3WObP81eU51RT2j8D8DULPM1OAPOnzYfODW8olB0xw'

密码设置

1、运行python
2、命令:from notebook.auth import passwd; passwd()
3、copy 密码

扩展插件

pip install jupyter_contrib_nbextensionsjupyter-contrib-nbextension install --user

在这里插入图片描述

后台运行

1、tmux new -s jupyter2jupyter notebook --ip=0.0.0.0 --port=9999 --allow-root3、然后我们按住快捷键Ctrl+b,松开,再按一下d。我们就把这个会话放到了后台。4、返回窗口:tmux attach -t jupyter

使用

在浏览器输入服务器的IP地址:9999,小编这里是34.81.173.39:9999,访问

参考

https://blog.csdn.net/zhangtingduo/article/details/133945890
https://baijiahao.baidu.com/s?id=1759085502704856128&wfr=spider&for=pc


http://www.ppmy.cn/ops/14869.html

相关文章

不要摆摊,不要开早餐店,原因如下

关注卢松松,会经常给你分享一些我的经验和观点。 我最近开通了视频号会员专区嘛,专区有个问答功能可以提问,有个会员问了我问题,其中一条问答分享给大家: 松哥,突然想去兼职,早上卖点杂粮煎饼果…

Mysql 的char 和varchar的的区别

1、char 和varchar 区别 下面以utf8字符集为例,char和varchar的占比计算,如下图 valueChar(5)bytesVarchar(5)bytesVarchar(100)bytes‘’‘ ’15‘’1‘’1‘abcd’‘abcd ’15‘abcd’13‘abcd’13abcdeabcde15abcde16abcde16 varchar使用…

日志集中审计系列(5)--- LogAuditor接收USG设备日志

日志集中审计系列(5)--- LogAuditor接收USG设备日志 前言拓扑图设备选型组网需求配置思路操作步骤结果验证前言 近期有读者留言:“因华为数通模拟器仅能支持USG6000V的防火墙,无法支持别的安全产品,导致很多网络安全的方案和产品功能无法模拟练习,是否有真机操作的实验或…

centos7开启指定端口操作步骤

开启指定端口如:80 firewall-cmd --zonepublic --add-port80/tcp --permanent--permanent:更改将永久生效,否则重启后失效。 可能会提示firewall服务没有开启 开启firewall服务 systemctl start firewalld也可以提前查看firewalld服务状态 systemctl status fi…

接口测试--apipost接口断言详解

在做接口测试的时候,会对接口进行断言,一个完整的接口测试,包括:请求->获取响应正文->断言。 一、apipost如何进行断言 apipost的断言设置实在后执行脚本中进行编写的。apipost本身提供了11中断言: apt.asser…

深入浅出SSH

诸神缄默不语-个人CSDN博文目录 SSH(Secure Shell)是一个用于计算机之间安全通信的协议。它广泛用于远程登录和其他网络服务,以确保数据在网络中传输的安全性和完整性。本文将介绍SSH的基础知识,以及如何在Windows 10系统中使用内…

如何解决Windows本地微服务并发启动后端口占用问题

在微服务架构中,经常会遇到本地开发时多个服务需要并行运行,而断开服务后由于某些原因导致端口未正确释放,再次启动服务时发现端口被占用的问题。这会阻碍开发进度,解决这一问题非常关键。本文将详细指导你如何在Windows环境下解决…

1003 - 编程求1+3+5+...+n

题目描述 编程求 135 \dots n135⋯n 。 输入 输入一行&#xff0c;只有一个整数 n (1 \le n \lt 10000)n(1≤n<10000) 这里 nn 为奇数。 输出 输出只有一行。 样例 输入 99 输出 2500 #include<bits/stdc.h> using namespace std; int main(){int m,s0;cin…