Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

619
Vistas
MongoDB docker container "Failed to unlink socket file"

I have MongoDB as docker container When I restarted the server and tried to start the container it kept restarting forever.

I got the container log as follows

enter image description here

The main problem is Failed to unlink socket file /tmp/mongodb-27017.sock Operation not permitted

I found many solutions to this problem, but all of them are based on the idea that I'm using the mongod service, which isn't my case.

I'm using a docker container and I can't run commands on this container until it is running. Sadly this error doesn't let the container start and keeps restarting.

I found the issue on the official bug tracker of MongoDB since version 3.6, but also it doesn't have any solution.

I also found a similar question on DigitalOcean support with no luck to find a solution.

over 4 years ago · Santiago Trujillo
2 Respuestas
Responde la pregunta

0

Warning!! When you create a MogoDB container, You should always link the directory /data/db inside your container to be on the host using Volumes.

In case /data/db isn't linked to a volume, you will lose your data.

Try to stop the container using docker stop <container>

then remove it completely using docker rm <container>

then re-build using docker build or docker-compose build depends on your usage

Note: Whenever you remove the container it's data will be removed along with it. so make sure that you have a recent backup with the database.

over 4 years ago · Santiago Trujillo Denunciar

0

I had this problem and i'd solved with docker-compose down and then docker-compose up. This problem is probably caused because your docker container is broken

over 4 years ago · Santiago Trujillo Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda