Skip to content

Cannot add blobfuse mounted volume #204

@andrinr

Description

@andrinr

Description

When trying to add a directory that was mounted using blobfuse2 to the volume argument serving will fail with:

Error response from daemon: error while creating mount source path '/home/azureuser/localfiles/local_datasets/sygaldry-gridded/checkpoints-small-grid-v2-3': mkdir /home/azureuser/localfiles/local_datasets/sygaldry-gridded: file exists

Steps to reproduce

tesseract serve vectoradd-jax  -v "<some-mounted-dir>:/tesseract/checkpoint"

Logs

ptim) (azureml_py38) azureuser@sygaldry8:~/localfiles/sygaldry$ tesseract serve dpp-unet-inference -v "/home/azureuser/localfiles/local_datasets/sygaldry-gridded/checkpoints-small-grid-v2-3:/tesseract/checkpoint"
/anaconda/envs/optim/lib/python3.12/site-packages/requests/__init__.py:86: RequestsDependencyWarning: Unable to find acceptable character detection dependency (chardet or charset_normalizer).
  warnings.warn(
 [i] Waiting for Tesseract containers to start ...
 [-] Command '['docker', 'compose', '-f', '/var/tmp/docker-compose-nm9qqnden9qa.yml5tsk8bxq', '-p', 'tesseract-pqdztn6oqyer', 'up', '-d', '--wait']' returned non-zero exit status 1.
 [-]  Network tesseract-pqdztn6oqyer_multi-tesseract-network  Creating
 Network tesseract-pqdztn6oqyer_multi-tesseract-network  Created
 Container tesseract-pqdztn6oqyer-sha256-md03z07eymkm-1  Creating
 Container tesseract-pqdztn6oqyer-sha256-md03z07eymkm-1  Created
 Container tesseract-pqdztn6oqyer-sha256-md03z07eymkm-1  Starting
Error response from daemon: error while creating mount source path '/home/azureuser/localfiles/local_datasets/sygaldry-gridded/checkpoints-small-grid-v2-3': mkdir /home/azureuser/localfiles/local_datasets/sygaldry-gridded: file exists

 [-] Container 4a0edd9a8ef00c5ecfdaf14cf15d347016fbe13de67a2441921c527890dc8b89 logs:
 [-] 
 [x] Uncaught error
╭─────────────────────────────── Traceback (most recent call last) ────────────────────────────────╮
│ /anaconda/envs/optim/lib/python3.12/site-packages/tesseract_core/sdk/docker_client.py:684 in up  │
│                                                                                                  │
│   681 │   │   docker_compose = _get_executable("docker-compose")                                 │
│   682 │   │   logger.info("Waiting for Tesseract containers to start ...")                       │
│   683 │   │   try:                                                                               │
│ ❱ 684 │   │   │   _ = subprocess.run(                                                            │
│   685 │   │   │   │   [                                                                          │
│   686 │   │   │   │   │   *docker_compose,                                                       │
│   687 │   │   │   │   │   "-f",                                                                  │
│                                                                                                  │
│ /anaconda/envs/optim/lib/python3.12/subprocess.py:573 in run                                     │
│                                                                                                  │
│    570 │   │   │   raise                                                                         │
│    571 │   │   retcode = process.poll()                                                          │
│    572 │   │   if check and retcode:                                                             │
│ ❱  573 │   │   │   raise CalledProcessError(retcode, process.args,                               │
│    574 │   │   │   │   │   │   │   │   │    output=stdout, stderr=stderr)                        │
│    575 │   return CompletedProcess(process.args, retcode, stdout, stderr)                        │
│    576                                                                                           │
╰──────────────────────────────────────────────────────────────────────────────────────────────────╯
CalledProcessError: Command '['docker', 'compose', '-f', '/var/tmp/docker-compose-nm9qqnden9qa.yml5tsk8bxq', '-p', 'tesseract-pqdztn6oqyer', 'up', '-d', '--wait']' returned non-zero exit status 1.

The above exception was the direct cause of the following exception:

╭─────────────────────────────── Traceback (most recent call last) ────────────────────────────────╮
│ /anaconda/envs/optim/lib/python3.12/site-packages/tesseract_core/sdk/engine.py:116 in            │
│ wrapper_needs_docker                                                                             │
│                                                                                                  │
│   113 │   │   │   raise UserError(                                                               │
│   114 │   │   │   │   "Could not reach Docker daemon, check if it is running."                   │
│   115 │   │   │   ) from ex                                                                      │
│ ❱ 116 │   │   return func(*args, **kwargs)                                                       │
│   117 │                                                                                          │
│   118 │   return wrapper_needs_docker                                                            │
│   119                                                                                            │
│                                                                                                  │
│ /anaconda/envs/optim/lib/python3.12/site-packages/tesseract_core/sdk/cli.py:495 in serve         │
│                                                                                                  │
│   492 │   │   ports = None                                                                       │
│   493 │                                                                                          │
│   494 │   try:                                                                                   │
│ ❱ 495 │   │   project_id = engine.serve(                                                         │
│   496 │   │   │   image_names,                                                                   │
│   497 │   │   │   host_ip,                                                                       │
│   498 │   │   │   ports,                                                                         │
│                                                                                                  │
│ /anaconda/envs/optim/lib/python3.12/site-packages/tesseract_core/sdk/engine.py:659 in serve      │
│                                                                                                  │
│   656 │   │   compose_file.flush()                                                               │
│   657 │   │                                                                                      │
│   658 │   │   project_name = f"tesseract-{_id_generator()}"
│ ❱ 659 │   │   if not docker_client.compose.up(compose_file.name, project_name):                  │
│   660 │   │   │   raise RuntimeError("Cannot serve Tesseracts")                                  │
│   661 │   │   return project_name                                                                │
│   662                                                                                            │
│                                                                                                  │
│ /anaconda/envs/optim/lib/python3.12/site-packages/tesseract_core/sdk/docker_client.py:710 in up  │
│                                                                                                  │
│   707 │   │   │   │   container = Containers.get(container_name)                                 │
│   708 │   │   │   │   logger.error(f"Container {container_name} logs:")                          │
│   709 │   │   │   │   logger.error(indent(container.logs(stderr=True).decode(), " > "))          │
│ ❱ 710 │   │   │   raise APIError("Failed to start Tesseract containers.") from ex                │
│   711 │                                                                                          │
│   712 │   @staticmethod                                                                          │
│   713 │   def down(project_id: str) -> bool:                                                     │
╰──────────────────────────────────────────────────────────────────────────────────────────────────╯
APIError: Failed to start Tesseract containers.
 [x] Aborting

OS

Linux

Tesseract version

0.9.1

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions