Skip to content

Troubleshoot Guide: Run with WSL (Windows) #148

@ronnypollak

Description

@ronnypollak

As I faced some problems to make the demo run with WSL on Windows I want to present the steps I have followed to make it work in case anyone else is facing the same issues:

I prepared the repo locally on my Windows (clone the project, copy the weights and the demo data), then switch to the WSL and mount the direction of the project.

My steps in WSL were as follows:

  1. Initialize WSL with Ubuntu 24.04
  2. Install the Docker Engine: https://docs.docker.com/engine/install/ubuntu/
  3. Pull the docker image
  4. You can then try to run the run_container.sh, if it works congrats if not you could have one of these issues:

Mount Error:

Fehler: access control disabled, clients can connect from any host docker: Error response from daemon: failed to create task for container: failed to create shim task: OCI runtime create failed: runc create failed: unable to start container process: error during container init: error running hook #0: error running hook: exit status 1, stdout: , stderr: Auto-detected mode as 'legacy'
nvidia-container-cli: mount error: file creation failed: /var/lib/docker/overlay2/cbf69331937d06db8d5e99606517e3e05d95d5fca454e5551271dd1a924c6caa/merged/usr/lib/x86_64-linux-gnu/[libnvidia-ml.so](http://libnvidia-ml.so/).1: file exists: unknown 

--> NVIDIA/nvidia-container-toolkit#289 (comment)
--> What I did here was:

  1. Create a new dockerfile, foundationpose-modified:
FROM foundationpose

RUN rm -rf /usr/lib/x86_64-linux-gnu/libnvidia-ml.so.1 /usr/lib/x86_64-linux-gnu/libcuda.so.1
  1. Create or modify: run_container-modified:
#!/bin/bash

# Remove any existing container named foundationpose
docker rm -f foundationpose

# Set the current directory
DIR=$(pwd)/../

# Allow connections to the X server
xhost +

# Run the Docker container using the modified image
docker run --gpus all --env NVIDIA_DISABLE_REQUIRE=1 -it --network=host --name foundationpose \
  --cap-add=SYS_PTRACE --security-opt seccomp=unconfined \
  -v $DIR:$DIR -v /home:/home -v /mnt:/mnt -v /tmp/.X11-unix:/tmp/.X11-unix -v /tmp:/tmp \
  --ipc=host -e DISPLAY=${DISPLAY} -e GIT_INDEX_FILE \
  foundationpose-modified bash -c "cd $DIR && bash"
  1. build it: build -t foundationpose-modified .
  2. Then run the modified run_container-modified.sh
  3. run the build_all.sh
  4. run the demo

Thank you to @wenbowen123 for this project and for pointing to resources in other, related issues.

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