JupyterLab post-install Error 500

Mon serveur YunoHost

Matériel: Ordinateur
Version de YunoHost: 11.2.11.3 (stable)
J’ai accès à mon serveur : En SSH | Par la webadmin
Êtes-vous dans un contexte particulier ou avez-vous effectué des modificiations particulières sur votre instance ? : non
Si oui, expliquer:
Si votre requête est liée à une applicatio, précisez son nom et sa version: jupyterlab v.4.1.4~ynh1

Description du problème

Bonjour a tous,

Je viens d’installer l’application JupyterLab depuis le store disponible via la webadmin. Apres l’installation j’ai acces a l’ecran de login de JupyterLab, mais une fois log une erreur 500 apparait :
" 500 : Internal Server Error
Unhandled error starting server ncarr
You can try restarting your server from the [home page]."

Sur la page home un seul bouton disponible “Start My Server”, quand je clique dessus je me retrouve avec la meme erreur.

Dans le panel admin, si je clique sur le bouton “Start Server”, je n’ai droit qu’a un message “Failed to start server.”. Le bouton “Spawn Page” quand a lui me retourne la fameuse erreur 500 citee au dessus.

Quelqu’un aurait-il deja rencontre le meme probleme ? (Je n’ai rien vu en farfouillant dans le forum) Si oui, comment le resoudre ?

A bientot, et merci pour votre aide !

I finally got a log after looking for the error 500 :

May 01 15:29:14 yunohost jupyterhub[3035951]: [I 2024-05-01 15:29:14.369 JupyterHub provider:660] Creating oauth client jupyterhub-user-user
May 01 15:29:14 yunohost jupyterhub[3035951]: [I 2024-05-01 15:29:14.383 JupyterHub spawner:1692] Spawning jupyterhub-singleuser --config=/opt/jupyterlab/config/jupyter_notebook_config.py
May 01 15:29:14 yunohost jupyterhub[3038374]: Failed to set groups [Errno 22] Invalid argument
May 01 15:29:14 yunohost jupyterhub[3035951]: [E 2024-05-01 15:29:14.390 JupyterHub spawner:1706] Permission denied trying to run '/opt/jupyterlab/venv/bin/jupyterhub-singleuser'. Does user have access to this file?
May 01 15:29:14 yunohost jupyterhub[3035951]: [E 2024-05-01 15:29:14.390 JupyterHub user:887] Unhandled error starting user's server: [Errno 13] Permission denied: 'jupyterhub-singleuser'
May 01 15:29:14 yunohost jupyterhub[3035951]:     Traceback (most recent call last):
May 01 15:29:14 yunohost jupyterhub[3035951]:       File "/opt/jupyterlab/venv/lib/python3.9/site-packages/jupyterhub/user.py", line 801, in spawn
May 01 15:29:14 yunohost jupyterhub[3035951]:         url = await gen.with_timeout(timedelta(seconds=spawner.start_timeout), f)
May 01 15:29:14 yunohost jupyterhub[3035951]:       File "/opt/jupyterlab/venv/lib/python3.9/site-packages/jupyterhub/spawner.py", line 1702, in start
May 01 15:29:14 yunohost jupyterhub[3035951]:         self.proc = Popen(cmd, **popen_kwargs)
May 01 15:29:14 yunohost jupyterhub[3035951]:       File "/usr/lib/python3.9/subprocess.py", line 951, in __init__
May 01 15:29:14 yunohost jupyterhub[3035951]:         self._execute_child(args, executable, preexec_fn, close_fds,
May 01 15:29:14 yunohost jupyterhub[3035951]:       File "/usr/lib/python3.9/subprocess.py", line 1823, in _execute_child
May 01 15:29:14 yunohost jupyterhub[3035951]:         raise child_exception_type(errno_num, err_msg, err_filename)
May 01 15:29:14 yunohost jupyterhub[3035951]:     PermissionError: [Errno 13] Permission denied: 'jupyterhub-singleuser'
May 01 15:29:14 yunohost jupyterhub[3035951]:     
May 01 15:29:14 yunohost jupyterhub[3035951]: [E 2024-05-01 15:29:14.406 JupyterHub web:1875] Uncaught exception POST /jupyterlab/hub/api/users/user/servers/?_xsrf=MnwxOjB8MTA6MTcxNDU3NjAzNnw1Ol94c3JmfDg4Ok1HWmhNalJqWW1NNFptTXhORFV3WW1Ka1l6SmpabVF5T0dWaE9UYzRZV1U2TnpJNE5XTXlZbVk1WmprME5ERTVOR0l4WWpFM016bGxabVUyWmpVeE1UYz18OWFkYWMxMWEzM2E1ODRjMmViMWFjZmE0NDkwYzZhODNkOTZlZmNmNTA5OTBjOTkwYjI0ZTg3OWNlZmE0ZDFjMQ (2a01:e0a:e09:3260::7954:2aa5)
May 01 15:29:14 yunohost jupyterhub[3035951]:     HTTPServerRequest(protocol='http', host='jupyter.my-domain', method='POST', uri='/jupyterlab/hub/api/users/user/servers/?_xsrf=MnwxOjB8MTA6MTcxNDU3NjAzNnw1Ol94c3JmfDg4Ok1HWmhNalJqWW1NNFptTXhORFV3WW1Ka1l6SmpabVF5T0dWaE9UYzRZV1U2TnpJNE5XTXlZbVk1WmprME5ERTVOR0l4WWpFM016bGxabVUyWmpVeE1UYz18OWFkYWMxMWEzM2E1ODRjMmViMWFjZmE0NDkwYzZhODNkOTZlZmNmNTA5OTBjOTkwYjI0ZTg3OWNlZmE0ZDFjMQ', version='HTTP/1.1', remote_ip='2a01:e0a:e09:3260::7954:2aa5')
May 01 15:29:14 yunohost jupyterhub[3035951]:     Traceback (most recent call last):
May 01 15:29:14 yunohost jupyterhub[3035951]:       File "/opt/jupyterlab/venv/lib/python3.9/site-packages/tornado/web.py", line 1790, in _execute
May 01 15:29:14 yunohost jupyterhub[3035951]:         result = await result
May 01 15:29:14 yunohost jupyterhub[3035951]:       File "/opt/jupyterlab/venv/lib/python3.9/site-packages/jupyterhub/apihandlers/users.py", line 566, in post
May 01 15:29:14 yunohost jupyterhub[3035951]:         await self.spawn_single_user(user, server_name, options=options)
May 01 15:29:14 yunohost jupyterhub[3035951]:       File "/opt/jupyterlab/venv/lib/python3.9/site-packages/jupyterhub/handlers/base.py", line 1178, in spawn_single_user
May 01 15:29:14 yunohost jupyterhub[3035951]:         await gen.with_timeout(
May 01 15:29:14 yunohost jupyterhub[3035951]:       File "/opt/jupyterlab/venv/lib/python3.9/site-packages/jupyterhub/handlers/base.py", line 1088, in finish_user_spawn
May 01 15:29:14 yunohost jupyterhub[3035951]:         await spawn_future
May 01 15:29:14 yunohost jupyterhub[3035951]:       File "/opt/jupyterlab/venv/lib/python3.9/site-packages/jupyterhub/user.py", line 905, in spawn
May 01 15:29:14 yunohost jupyterhub[3035951]:         raise e
May 01 15:29:14 yunohost jupyterhub[3035951]:       File "/opt/jupyterlab/venv/lib/python3.9/site-packages/jupyterhub/user.py", line 801, in spawn
May 01 15:29:14 yunohost jupyterhub[3035951]:         url = await gen.with_timeout(timedelta(seconds=spawner.start_timeout), f)
May 01 15:29:14 yunohost jupyterhub[3035951]:       File "/opt/jupyterlab/venv/lib/python3.9/site-packages/jupyterhub/spawner.py", line 1702, in start
May 01 15:29:14 yunohost jupyterhub[3035951]:         self.proc = Popen(cmd, **popen_kwargs)
May 01 15:29:14 yunohost jupyterhub[3035951]:       File "/usr/lib/python3.9/subprocess.py", line 951, in __init__
May 01 15:29:14 yunohost jupyterhub[3035951]:         self._execute_child(args, executable, preexec_fn, close_fds,
May 01 15:29:14 yunohost jupyterhub[3035951]:       File "/usr/lib/python3.9/subprocess.py", line 1823, in _execute_child
May 01 15:29:14 yunohost jupyterhub[3035951]:         raise child_exception_type(errno_num, err_msg, err_filename)
May 01 15:29:14 yunohost jupyterhub[3035951]:     PermissionError: [Errno 13] Permission denied: 'jupyterhub-singleuser'
May 01 15:29:14 yunohost jupyterhub[3035951]:     
May 01 15:29:14 yunohost jupyterhub[3035951]: [E 2024-05-01 15:29:14.407 JupyterHub log:184] {
May 01 15:29:14 yunohost jupyterhub[3035951]:       "X-Forwarded-Port": "80",
May 01 15:29:14 yunohost jupyterhub[3035951]:       "Auth-User": "user",
May 01 15:29:14 yunohost jupyterhub[3035951]:       "Name": "user name",
May 01 15:29:14 yunohost jupyterhub[3035951]:       "Email": "user@my-domain",
May 01 15:29:14 yunohost jupyterhub[3035951]:       "Remote-User": "user",
May 01 15:29:14 yunohost jupyterhub[3035951]:       "Authorization": "Basic [secret]",
May 01 15:29:14 yunohost jupyterhub[3035951]:       "Cookie": "jupyterhub-hub-login=[secret]; _xsrf=[secret]; jupyterhub-session-id=[secret]; SSOwAuthUser=[secret]; SSOwAuthHash=[secret]; SSOwAuthExpire=[secret]",
May 01 15:29:14 yunohost jupyterhub[3035951]:       "Priority": "u=1, i",
May 01 15:29:14 yunohost jupyterhub[3035951]:       "Accept-Language": "fr-FR,fr;q=0.9,en-US;q=0.8,en;q=0.7",
May 01 15:29:14 yunohost jupyterhub[3035951]:       "Referer": "https://jupyter.my-domain/jupyterlab/hub/admin",
May 01 15:29:14 yunohost jupyterhub[3035951]:       "Sec-Fetch-Dest": "empty",
May 01 15:29:14 yunohost jupyterhub[3035951]:       "Sec-Fetch-Mode": "cors",
May 01 15:29:14 yunohost jupyterhub[3035951]:       "Sec-Fetch-Site": "same-origin",
May 01 15:29:14 yunohost jupyterhub[3035951]:       "Origin": "https://jupyter.my-domain",
May 01 15:29:14 yunohost jupyterhub[3035951]:       "Sec-Ch-Ua-Platform": "\"Linux\"",
May 01 15:29:14 yunohost jupyterhub[3035951]:       "User-Agent": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/124.0.0.0 Safari/537.36",
May 01 15:29:14 yunohost jupyterhub[3035951]:       "Sec-Ch-Ua-Mobile": "?0",
May 01 15:29:14 yunohost jupyterhub[3035951]:       "Content-Type": "application/json",
May 01 15:29:14 yunohost jupyterhub[3035951]:       "Accept": "application/jupyterhub-pagination+json",
May 01 15:29:14 yunohost jupyterhub[3035951]:       "Sec-Ch-Ua": "\"Not-A.Brand\";v=\"99\", \"Chromium\";v=\"124\"",
May 01 15:29:14 yunohost jupyterhub[3035951]:       "Content-Length": "0",
May 01 15:29:14 yunohost jupyterhub[3035951]:       "Connection": "upgrade",
May 01 15:29:14 yunohost jupyterhub[3035951]:       "X-Forwarded-Host": "jupyter.my-domain",
May 01 15:29:14 yunohost jupyterhub[3035951]:       "X-Forwarded-For": "2a01:e0a:e09:3260::7954:2aa5,::ffff:127.0.0.1",
May 01 15:29:14 yunohost jupyterhub[3035951]:       "X-Forwarded-Proto": "https,http",
May 01 15:29:14 yunohost jupyterhub[3035951]:       "X-Real-Ip": "2a01:e0a:e09:3260::7954:2aa5",
May 01 15:29:14 yunohost jupyterhub[3035951]:       "Host": "jupyter.my-domain"
May 01 15:29:14 yunohost jupyterhub[3035951]:     }

I’ve looked at the groups and users. My user has access to jupyterlab group.
So I don’t know where this “Permission denied” come from.

So I’ve tried to play a little with permission.
I need my user to own the folder /opt/jupyterlab for the scripts to work.
Even though my user is in the jupyterlab group and the jupyterlab group owns the folder

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.