Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

205
Views
customized Docker mongodb image gets stuck : can't stop, kill, open

I made NodeJS & mongoDB Docker image, Here is Dockerfile:

FROM ubuntu:14.04
MAINTAINER K. Haejin "haejin.kim419@gmail.com"

ENV DEBIAN_FRONTEND noninteractive

RUN apt-get update
RUN apt-get -qq update
RUN apt-get install -y nodejs npm
RUN apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv 7F0CEB10
RUN echo 'deb http://downloads-distro.mongodb.org/repo/ubuntu-upstart dist 10gen' | tee /etc/apt/sources.list.d/10gen.list
RUN apt-get update && apt-get install -y mongodb-org=2.6.1 mongodb-org-server=2.6.1 mongodb-org-shell=2.6.1 mongodb-org-mongos=2.6.1 mongodb-org-tools=2.6.1

RUN update-alternatives --install /usr/bin/node node /usr/bin/nodejs 10
RUN mkdir -p /data/db

VOLUME ["/data"]

ADD . /data
WORKDIR /data

EXPOSE 8000
EXPOSE 27017

CMD ["mongod"]

I built it to "mongo_node" image, and run container by following command :

docker run -it --name mongo_node -v "$(pwd)":/data -p 8000:8000 -p 27017:27017 mongo_node bash

But when I push large file(400MB) into mongoDB by 'mongoimport' command, Container gets stuck. It is still running however, I can not get inside(docker exec -it mongo_node bash), can not stop(docker stop mongo_node) and kill. It can be stopped by restart my desktop(if It happens in server.. server should be reseted.. It is horrible). I think problem is my Dockerfile because I've never seen this problem in standard mongodb image.

over 4 years ago · Santiago Trujillo
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!