Search code examples
singularity-container

Singularity: failed to resolve session directory


I wrote a Singularity container that works just fine on my computer. However, when a colleague of mine tries to run it, he gets the error output

FATAL:   container creation failed: failed to resolve session directory /usr/local/var/singularity/mnt/session: lstat /usr/local/var: no such file or directory

In the past, he could run containers I build. In fact, he used being able to run a container with the same recipe. The change was that the version of Singularity on the machine I use to build it was upgraded.

I entered the error in a search engine, and I only found a single hit, https://forum.image.sc/t/improving-cluster-supercomputer-performance-tesla-v100-volta-16-32gb-gpu/37459/8, in which this is not resolved.

Does anybody know a way to fix this? Or what the source of the problem is? Or a workaround, preferably one that does not require me to downgrade Singularity? (The machine on which I build it is shared between several users, that's why I don't want to do that.)


Solution

  • Okay, this was somewhat trivial to solve, we just had the colleague create the required folder,

    mkdir -p /usr/local/var/singularity/mnt/{container,final,overlay,session}