When the server machine restarts, the users' data is lost

When the server machine (the machines that contains pods) restarts, the JupyterHub doesn’t detect the previous data from any user

Hi folks, I did some tests and this still looks like true…
There is a way to resolve this problem? There is some expectation of this bug be resolved in a new release?


documentation link: Customizing User Storage — Zero to JupyterHub with Kubernetes documentation

Are you adding an external persistent storage source? A caveat of being deployed on Kubernetes is that storage created inside the pod is ephemeral— meaning the storage dies when the pod dies. It is necessary to plan for an outside permanent storage arrangement.

For our case, I solved this problem by using an environment variable inside Jupyterhub configs to read the LDAP username which the user authenticated with. The storage appliance that is mounted also provides user directories corresponding to the LDAP username. So there is a convenient option to mount a user specific working directory for persistent storage.

If this sounds relevant to your use case, I am happy to compare more detailed notes.

Best,
Monica

1 Like