added a jupyterhub troubleshooting page

This commit is contained in:
feichtinger 2020-02-18 18:03:07 +01:00
parent 5bf1a50c63
commit ce66ca0b86
3 changed files with 68 additions and 3 deletions

View File

@ -67,6 +67,8 @@ entries:
url: /merlin6/jupyter-extensions.html
- title: Jupyterlab
url: /merlin6/jupyterlab.html
- title: Jupyterhub Troubleshooting
url: /merlin6/jupyterhub-trouble.html
- title:
- title: Announcements
folderitems:

View File

@ -0,0 +1,63 @@
---
title: Jupyterhub Troubleshooting
#tags:
#keywords:
last_updated: 18 February 2020
#summary: ""
sidebar: merlin6_sidebar
permalink: /merlin6/jupyterhub-trouble.html
---
In case of problems or requests, please either submit a **[PSI Service Now](https://psi.service-now.com/psisp)** incident containing *"Merlin Jupyterhub"* as part of the subject, or contact us by mail through <merlin-admins@lists.psi.ch>.
## General steps for troubleshooting
### Investigate the Slurm output file
Your jupyterhub session runs as a normal batch job on the cluster, and each launch will create a slurm output file in your HOME directory named like `jupyterhub_batchspawner_{$JOBID}.log`, where the $JOBID part is the slurm job ID of your job. After a failed launch, investigate the contents of that file. An error message will usually be found towards the end of the file, often including a python backtrace.
### Investigate python environment interferences
Jupyterhub just runs a jupyter notebook executable as your user inside the batch job. A frequent source of errors consists of a user's local python environment definitions getting mixed up with the environment that jupyter needs to launch.
- setting PYTHONPATH inside of the ~/.bash_profile or any other startup script
- having installed packages to your local user area (e.g. using `pip install --user <some-package>`). Such installation will interfere with the environment offered by the `module` system on our cluster (based on anaconda). You can list such packages by executing
`pip list user`. They are usually located in `~/.local/lib/pythonX.Y/...`.
You can investigate the launching of a notebook interactively, by logging in to Merlin6 and running a jupyter command in the correct environment.
```
module use unstable
module load anaconda/2019.07
conda activate jupyterhub-1.0.0_py36
jupyter --paths
```
## Known Problems and workarounds
### Spawner times out
If the cluster is very full, it may be difficult to launch a session. We always reserve some slots for interactive Jupyterhub use, but it may be that these slots have been taken or that the resources you requested are currently not available.
Inside of a Merlin6 terminal shell, you can run the standard commands like `sinfo` and `squeue` to get an overview of how full the cluster is.
### Your user environment is not among the kernels offered for choice
Refer to our documentation about [using your own custom made
environments with jupyterhub](/merlin6/jupyterhub.html).
### Cannot save notebook - _xsrf argument missing_
You cannot save your notebook anymore and you get this error:
**'_xsrf' argument missing from POST**
This issue occurs very seldomly. There exists the following workaround:
Go to the jupyterhub file browsing window and just open another
notebook using the same kernel in another browser window. The issue
should then go away. For more information refer to [this github
thread](https://github.com/nteract/hydrogen/issues/922#issuecomment-405456346)
<!-- ## Error HTTP 500 when starting the spawner -->
<!-- The spawner screen shows after launching an error message like the following: -->
<!-- `Internal server error (Spawner failed to start [status=..]. The logs may contain details)` -->

View File

@ -77,7 +77,7 @@ After this, your new kernel will be visible as `my-test-env` inside of your jupy
## Troubleshooting
## Contact
In case of problems or requests, please either submit a **[PSI Service Now](https://psi.service-now.com/psisp)** incident containing *"Merlin Jupyterhub"* as part of the subject, or contact us by mail through <merlin-admins@lists.psi.ch>.
In case of problems or request, please either submit a **[PSI Service Now](https://psi.service-now.com/psisp)** incident containing *"Merlin Jupyterhub"* as part of the subject, or contact us by mail through <merlin-admins@lists.psi.ch>.