Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Jupyter Notebook on FreeBSD 12.1 Jail. Connection to kernel fails #5775

Open
leonardorame opened this issue Sep 26, 2020 · 1 comment
Open

Comments

@leonardorame
Copy link

leonardorame commented Sep 26, 2020

Hi, I'm trying to run Jupyter Notebook and JupyterLab on a FreeBSD 12.1 Jail. I've been trying to make it work since more than a week ago without success.

I installed it first using pkg install and when I found this problem I tried with pip3 install ...., but both methods ends with the same problem.

After installing and making some changes in the config file /home/jupyter/.jupyter/jupyter_notebook_config.py I can open it from a web browser. The changes are these:

c.NotebookApp.ip ='*'
c.NotebookApp.open_browser = False
c.NotebookApp.notebook_dir  = '/tmp'
c.NotebookApp.port = 8888

I can point from another machine using http://192.168.0.111:8888, and get this:

image

So everything seems to be working...until I try do execute a simple calc like 1+1 or print("hello world"). When I do that and press ctrl+r there's a Kernel starting, please wait..., and after a while, in the server's console there's this:

[I 16:23:09.145 NotebookApp] Creating new notebook in 
/usr/local/lib/python3.7/site-packages/jupyter_client/connect.py:164: RuntimeWarning: Failed to set sticky bit on '/usr/home/jupyter/.local/share/jupyter/runtime/kernel-67e1b082-cc4e-4b25-b5a5-a38d13fd717f.json': [Errno 79] Inappropriate file type or format: '/usr/home/jupyter/.local/share/jupyter/runtime/kernel-67e1b082-cc4e-4b25-b5a5-a38d13fd717f.json'
Probably not a big deal, but runtime files may be cleaned up periodically.
  RuntimeWarning,
[I 16:23:10.143 NotebookApp] Kernel started: 67e1b082-cc4e-4b25-b5a5-a38d13fd717f
[W 16:23:10.192 NotebookApp] 404 GET /nbextensions/widgets/notebook/js/extension.js?v=20200926161340 (192.168.0.110) 0.99ms referer=http://192.168.0.111:8888/notebooks/Untitled4.ipynb?kernel_name=python3
/usr/local/lib/python3.7/site-packages/jupyter_client/connect.py:164: RuntimeWarning: Failed to set sticky bit on '/usr/home/jupyter/.local/share/jupyter/runtime/kernel-67e1b082-cc4e-4b25-b5a5-a38d13fd717f.json': [Errno 79] Inappropriate file type or format: '/usr/home/jupyter/.local/share/jupyter/runtime/kernel-67e1b082-cc4e-4b25-b5a5-a38d13fd717f.json'
Probably not a big deal, but runtime files may be cleaned up periodically.
  RuntimeWarning,
[I 16:23:17.731 NotebookApp] Saving file at /Untitled3.ipynb
[W 16:23:31.238 NotebookApp] Replacing stale connection: 67e1b082-cc4e-4b25-b5a5-a38d13fd717f:f20bd23a2dc0450c8f9db79d7eb82a33
[W 16:23:54.305 NotebookApp] Replacing stale connection: 67e1b082-cc4e-4b25-b5a5-a38d13fd717f:f20bd23a2dc0450c8f9db79d7eb82a33
[W 16:24:10.227 NotebookApp] Timeout waiting for kernel_info reply from 67e1b082-cc4e-4b25-b5a5-a38d13fd717f
[I 16:24:10.234 NotebookApp] Starting buffering for 67e1b082-cc4e-4b25-b5a5-a38d13fd717f:f20bd23a2dc0450c8f9db79d7eb82a33
[I 16:24:10.235 NotebookApp] Restoring connection for 67e1b082-cc4e-4b25-b5a5-a38d13fd717f:f20bd23a2dc0450c8f9db79d7eb82a33
jupyter core     : 4.6.3
jupyter-notebook : 6.0.3
qtconsole        : not installed
ipython          : 7.16.1
ipykernel        : 5.3.0
jupyter client   : 6.1.3
jupyter lab      : not installed
nbconvert        : 5.6.1
ipywidgets       : not installed
nbformat         : 5.0.7
traitlets        : 4.3.3

By searching on the web I found others have a similar issue with tornado 6, but this installation is running py37-tornado-5.1.1 which is installed automatically by pkg install notebook.

Can anyone help me with this?

@leonardorame
Copy link
Author

I can confirm it works without issues on the host, but not in a jail.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant