# Error in Pulling Docker Image using Singularity

**URL:** <https://opendata-forum.cern.ch/t/error-in-pulling-docker-image-using-singularity/263>\
**Category:** Containers\
**Created:** [13 February 2024 03:14 UTC](https://opendata-forum.cern.ch/t/error-in-pulling-docker-image-using-singularity/263 "2024-02-13T03:14:49Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![rgsohal](https://opendata-forum.cern.ch/letter_avatar_proxy/v4/letter/r/a88e57/32.png) [@rgsohal](https://opendata-forum.cern.ch/u/rgsohal)\
**Post date:** [13 February 2024 03:14 UTC](https://opendata-forum.cern.ch/t/error-in-pulling-docker-image-using-singularity/263/1 "2024-02-13T03:14:49Z")

</div>

I am trying to get myself familiar with operations related to our cluster, so I tried using singularity there. I am having issues with pulling a specific docker image into singularity in the cluster. I have done the following steps:

```auto
cd /scratch/$USER
mkdir -p singularity/{cache,temp}
mkdir my_containers
module load singularity/3.7.2
export SINGULARITY_CACHEDIR=/scratch/$USER/singularity/cache
export SINGULARITY_TMPDIR=/scratch/$USER/singularity/temp
cd my_containers
singularity pull ./cms7poet.sif docker://cmsopendata/cmssw_7_6_7-slc6_amd64_gcc493

```

After the conversion of blob OCI to SIF, specifically saying

```auto
Writing manifest to image destination
Storing signatures
... warn xattr{mnt}
... warn xattr{lib}
... warn rootless{rootfs/}
...

```

it then throws a bunch of warnings and at the end of the day, returns the error

```auto
While making image from oci registry: error fetching image to cache: while building SIF from layers: packer failed to pack: while unpacking tmpfs: error unpacking rootfs: unpack layer: unpack entry: var/lib/yum/yumdb/m/d1e78f5adcafeb6c7d05cf71d17fb5196f487db5-mesa-libgbm-11.0.7-4.el6-x86_64/checksum_type: link: unpriv.link: unpriv.wrap target: too many links

```

I tried adding `chmod -R 777 [directory]` from the very beginning, but it did not work. I also tried googling first the issue, but never got a particular answer for it. Does anyone know about how to get around this kind of error? The available version of singularity that I am using is version 3.7.2, and the docker image is from CERN.

---

<div class="post-metadata">

**Author:** ![katilp](https://opendata-forum.cern.ch/user_avatar/opendata-forum.cern.ch/katilp/32/132_2.png) [@katilp](https://opendata-forum.cern.ch/u/katilp)\
**Post date:** [19 February 2024 07:49 UTC](https://opendata-forum.cern.ch/t/error-in-pulling-docker-image-using-singularity/263/2 "2024-02-19T07:49:33Z")

</div>

Hello!

Thanks for your message!  
We do not have much experience yet using the CMS OD docker images with apptainer/singularity but we were able to do so in the recent workshop session in January ([Analyzing Open Data at Scale](https://cms-opendata-workshop.github.io/workshopwhepp-lesson-condor/))

Pulling the image took very long (and gave a long list of warning messages) but it finally succeeded. Does your SINGULARITY\_CACHEDIR have enough space?

If you have the possibility of having the cvmfs file system mounted on your cluster, there might be more convenient options than converting the docker image.

Best, Kati

---

<div class="post-metadata">

**Author:** ![rgsohal](https://opendata-forum.cern.ch/letter_avatar_proxy/v4/letter/r/a88e57/32.png) [@rgsohal](https://opendata-forum.cern.ch/u/rgsohal)\
**Post date:** [19 February 2024 15:33 UTC](https://opendata-forum.cern.ch/t/error-in-pulling-docker-image-using-singularity/263/3 "2024-02-19T15:33:08Z")

</div>

Hi! Thank you so much for your response. I think there is an option of having cvmfs mounted in the cluster. Can you share some resources that I read about tutorials on getting cmssw setup on it? Thank you!
