Change Jupyter Notebook's localhost:8888 default server with other

前端 未结 3 1697
被撕碎了的回忆
被撕碎了的回忆 2021-01-03 00:01

i have two machines connected via lan. other system\'s ip address is 192.1xx.x.x i want to run jupyter ipython query\'s on my machine which can be exexuted on his machine. a

3条回答
  •  走了就别回头了
    2021-01-03 00:58

    First you need to generate a configuration file by typing:

    $> jupyter notebook --generate-config
    Writing default config to: /{home-directory}/.jupyter/jupyter_notebook_config.py
    

    Next you need to edit that configuration to change the port number:

    vi /{home-directory}/.jupyter/jupyter_notebook_config.py
    

    Look for the following line (which is commented out by default) and comment in the line and change the port number:

    (default configuration)
    ## The port the notebook server will listen on.
    # c.NotebookApp.port = 8888
    
    (comment removed, port changed)
    ## The port the notebook server will listen on.
    c.NotebookApp.port = 9999
    

提交回复
热议问题