Skip to content

TLJH: Rules.toml can't be replaced  #111

@ghost

Description

Hello,
I'm trying to use TLJK in a LXC, Ubuntu 16.04 updated. I follow the default configuration (not very complicated ...) but i have some issues when starting jupyterhub.

/opt/tljh/hub/lib/python3.6/site-packages/jupyterhub_traefik_proxy/traefik_utils.py:42: RuntimeWarning: Escape character '_' cannot be a safe character. Set allow_collisions=True if you want to allow ambiguous escaped strings. return server_type + "_" + escapism.escape(routespec, safe=safe) [E 2020-05-29 11:16:45.215 JupyterHub app:2718] Traceback (most recent call last): File "/opt/tljh/hub/lib/python3.6/site-packages/jupyterhub/app.py", line 2716, in launch_instance_async await self.start() File "/opt/tljh/hub/lib/python3.6/site-packages/jupyterhub/app.py", line 2614, in start await self.proxy.check_routes(self.users, self._service_map) File "/opt/tljh/hub/lib/python3.6/site-packages/jupyterhub/proxy.py", line 63, in locked_method return await method(*args, **kwargs) File "/opt/tljh/hub/lib/python3.6/site-packages/jupyterhub/proxy.py", line 394, in check_routes await gen.multi(futures) File "/opt/tljh/hub/lib/python3.6/site-packages/tornado/gen.py", line 501, in callback result_list.append(f.result()) File "/opt/tljh/hub/lib/python3.6/site-packages/jupyterhub_traefik_proxy/toml.py", line 191, in add_route self.toml_dynamic_config_file, self.routes_cache File "/opt/tljh/hub/lib/python3.6/site-packages/jupyterhub_traefik_proxy/traefik_utils.py", line 153, in persist_routes toml.dump(routes_dict, config_fd) File "/usr/lib/python3.6/contextlib.py", line 88, in __exit__ next(self.gen) File "/opt/tljh/hub/lib/python3.6/site-packages/jupyterhub_traefik_proxy/traefik_utils.py", line 137, in atomic_writing os.replace(fileobj.name, path) OSError: [Errno 16] Device or resource busy: '/opt/tljh/state/rules.toml-tmp-57z3bbg6' -> '/opt/tljh/state/rules.toml'

I don't understand why, but sometimes i can't even go to the first page because of this error, and sometimes i can login with the first user, then the jupyter notebook can't load because it can't create the URL for my notebook (and same problem, it can't replace the temp rules in the rules.toml), depending on if i i systemctl stop/start traefik before starting jupyterhub, or even by using the /opt/tljh/hub/lib/python3.6/site-packages/tljh/jupyterhub_config.py --upgrade-db command in the /opt/tljh/state directory.

Any ideas ?

Thanks a lot !

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions