【Python】jupyter Linux服务器使用

文章目录

  • 环境
  • 使用
  • 访问

环境

pip install jupyter 

使用

在你想访问的目录下执行:

jupyter notebook --ip=0.0.0.0

jupyter 给出提示:

[I 2023-07-28 14:32:43.589 ServerApp] Package notebook took 0.0000s to import
[I 2023-07-28 14:32:43.597 ServerApp] Package jupyter_lsp took 0.0081s to import
[W 2023-07-28 14:32:43.597 ServerApp] A `_jupyter_server_extension_points` function was not found in jupyter_lsp. Instead, a `_jupyter_server_extension_paths` function was found and will be used for now. This function name will be deprecated in future releases of Jupyter Server.
[I 2023-07-28 14:32:43.601 ServerApp] Package jupyter_server_terminals took 0.0034s to import
[I 2023-07-28 14:32:43.601 ServerApp] Package jupyterlab took 0.0000s to import
[I 2023-07-28 14:32:43.639 ServerApp] Package notebook_shim took 0.0000s to import
[W 2023-07-28 14:32:43.640 ServerApp] A `_jupyter_server_extension_points` function was not found in notebook_shim. Instead, a `_jupyter_server_extension_paths` function was found and will be used for now. This function name will be deprecated in future releases of Jupyter Server.
[I 2023-07-28 14:32:43.640 ServerApp] jupyter_lsp | extension was successfully linked.
[I 2023-07-28 14:32:43.643 ServerApp] jupyter_server_terminals | extension was successfully linked.
[I 2023-07-28 14:32:43.647 ServerApp] jupyterlab | extension was successfully linked.
[I 2023-07-28 14:32:43.651 ServerApp] notebook | extension was successfully linked.
[I 2023-07-28 14:32:43.654 ServerApp] Writing Jupyter server cookie secret to /home/xiedong/.local/share/jupyter/runtime/jupyter_cookie_secret
[I 2023-07-28 14:32:43.827 ServerApp] notebook_shim | extension was successfully linked.
[I 2023-07-28 14:32:43.930 ServerApp] notebook_shim | extension was successfully loaded.
[I 2023-07-28 14:32:43.932 ServerApp] jupyter_lsp | extension was successfully loaded.
[I 2023-07-28 14:32:43.933 ServerApp] jupyter_server_terminals | extension was successfully loaded.
[I 2023-07-28 14:32:43.934 LabApp] JupyterLab extension loaded from /ssd/xiedong/miniconda3/envs/py38_diffusers_1/lib/python3.8/site-packages/jupyterlab
[I 2023-07-28 14:32:43.934 LabApp] JupyterLab application directory is /ssd/xiedong/miniconda3/envs/py38_diffusers_1/share/jupyter/lab
[I 2023-07-28 14:32:43.935 LabApp] Extension Manager is 'pypi'.
[I 2023-07-28 14:32:43.937 ServerApp] jupyterlab | extension was successfully loaded.
[I 2023-07-28 14:32:43.939 ServerApp] notebook | extension was successfully loaded.
[I 2023-07-28 14:32:43.939 ServerApp] Serving notebooks from local directory: /ssd/xiedong/workplace
[I 2023-07-28 14:32:43.939 ServerApp] Jupyter Server 2.7.0 is running at:
[I 2023-07-28 14:32:43.939 ServerApp] http://gpu20:8888/tree?token=490e738359e9e3a73247822c61620bacdfcae0038a9a721e
[I 2023-07-28 14:32:43.939 ServerApp]     http://127.0.0.1:8888/tree?token=490e738359e9e3a73247822c61620bacdfcae0038a9a721e
[I 2023-07-28 14:32:43.939 ServerApp] Use Control-C to stop this server and shut down all kernels (twice to skip confirmation).
[W 2023-07-28 14:32:43.948 ServerApp] No web browser found: Error('could not locate runnable browser').

记住这提示里的token:
490e738359e9e3a73247822c61620bacdfcae0038a9a721e

访问

windows电脑浏览器访问:

http://10.20.31.20:8888

默认端口8888,前面的ip需要填写你Linux服务器的IP。

你可能感兴趣的:(Python语言,python,服务器,jupyter)