-2

Why when I exit the terminal(xshell) in Ubuntu 14.10 does my mongoDB(2.6.8)server also terminate?

Elder Geek
  • 36,752

1 Answers1

1

When you start the mongo DB server it gets created as a child process of the terminal, so when you exit the terminal the child process are also terminated. To get around this you need to run the service as a daemon, the easiest way to do this is using the service command, assuming you installed Mongo DB following the documentation.

sudo service mongod start
AJefferiss
  • 1,154
  • 9
  • 17