【问题标题】:Unable to start jupyter无法启动 jupyter
【发布时间】:2016-04-09 15:28:24
【问题描述】:

当我尝试运行 jupyter 时,它显示了这个错误:-

错误:无法启动笔记本服务器,因为找不到可用端口。

终端日志如下:-

[I 20:52:08.747 NotebookApp] The port 8888 is already in use, trying another random port.
[I 20:52:08.748 NotebookApp] The port 8889 is already in use, trying another random port.
[I 20:52:08.748 NotebookApp] The port 8890 is already in use, trying another random port.
[I 20:52:08.749 NotebookApp] The port 8891 is already in use, trying another random port.
[I 20:52:08.750 NotebookApp] The port 8892 is already in use, trying another random port.
[I 20:52:08.750 NotebookApp] The port 8988 is already in use, trying another random port.
[C 20:52:08.779 NotebookApp] ERROR: the notebook server could not be started because no available port could be found.

而且,我还检查了我的系统以检查哪个进程正在该端口上运行,我发现没有进程正在运行,并且这些端口都没有被任何进程使用。但是,我仍然收到该错误。

我还将 jupyter 的默认端口更改为其他各种端口,但仍然出现相同的错误。

【问题讨论】:

    标签: ipython jupyter jupyter-notebook


    【解决方案1】:

    我遇到了同样的问题,然后运行

    jupyter notebook --port 9999 
    

    【讨论】:

      【解决方案2】:

      这项工作为我工作jupyter notebook stop 8888jupyter notebook --ip=0.0.0.0 --port=8888
      我找到了解决方案here

      【讨论】:

        【解决方案3】:

        错误可能不是jupyter引起的,而是你的系统引起的。

        要解决这个问题,你可以尝试在 8888 端口上打开一个简单的 http 服务器,看看失败的消息是否相同。

        您可以尝试以下命令之一来启动 http 服务器:

        python -m SimpleHTTPServer 8888 (Python2)
        python -m http.server 8888  (Python3)
        

        【讨论】:

          【解决方案4】:

          我曾经遇到过这个。这是因为你的翻译。您当前项目的版本解释器不适合您的 anaconda。您可以更改您的解释器,然后连接 jupyter。这可能会有所帮助。 (:D

          【讨论】:

            【解决方案5】:

            我知道这听起来很傻,但我刚刚遇到这个问题并重新启动我的操作系统,错误就消失了!

            【讨论】:

              【解决方案6】:

              解决方案在 Ubuntu 和 WSL 中很简单:

              jupyter notebook --allow-root --port 9999
              

              【讨论】:

                猜你喜欢
                • 1970-01-01
                • 1970-01-01
                • 2022-12-07
                • 1970-01-01
                • 1970-01-01
                • 2021-04-14
                • 2018-08-15
                • 2019-08-15
                • 2018-10-07
                相关资源
                最近更新 更多