Welcome Guest. Please Login or Register  


You are here: Index > AMPPS > Suggestions > Topic : Autostart/service for MongoDB



Normal Mode | Print  

Autostart/service for MongoDB
allanonk4
Group: Member
Post Group: Newbie
Posts: 1
Status:
I installed softaculous ammps and was wondering this very thing. I was able to get this working doing the following:

1) stop mongo if it's started

2) Find your mongo.conf. It's most likely in <ammps-install-directory>\mongodb\mongo.conf

This has the paths that mongo is using for the dbpath and logpath parameters as well as the other options it needs. You need to replicate those on the command line to get it to run as a service in ammps style.

3) run cmd as admistrator, change directory to  <ammps-install-directory>\mongodb\bin
and run this command, replacing the parameters for what's in your mongo.conf

mongod  --install --dbpath="<config-dbpath>" --logpath="<config-logpath>" --port 27017 --logappend --directoryperdb --rest --journal

4) run services.msc

5) 4) If you get any errors when starting the service, open your log file and see what they are. It's probably some switch that needs to be added. In my case, not having --journal was causing mongo to stop. run mongod --remove to remove the service that you created and repeat step 3 with the new options

6) start mongo and set to automatic start up if it isn't already (it should be)

7) enjoy automatic startup of mongo, yay!
IP: --   


Threads
 asegura   Autostart/service for MongoDB (4 Replies, Read 94375 times)
    |--  asegura   BTW, here is...   on July 29, 2015, 5:00 pm
    |--  asegura   AMPPS 3.4 is...   on January 21, 2016, 10:53 am
    |--  allanonk4   I installed softaculous...   on February 4, 2016, 6:17 pm
    |--  abiella   All the problems...   on May 30, 2017, 12:58 pm

« Previous    Next »

Normal Mode | Print  



Users viewing this topic
1 guests, 0 users.


All times are GMT. The time now is June 7, 2025, 7:13 pm.

  Powered By AEF 1.0.8 © 2007-2008 Electron Inc.Queries: 10  |  Page Created In:0.010