How to restart / stop arangodb server on mac osx

I follow the first part of the documentation for arangodb 2.7.3. I did it before

brew install /usr/local/sbin/arangod & 

The very next section, after installing on the basic cluster setup, is written for people using linux. It will ask you to change the configuration file that I made, followed by restarting arango via /etc/init.d/arangodb . What is the correct way to restart the arango daemon on mac osx?

+5
source share
3 answers

You should use the usual home start / stop method , which also works for ArangoDB.

Quote from brew install arangodb :

To start startar arangodb at login:

 ln -sfv /usr/local/opt/arangodb/*.plist ~/Library/LaunchAgents 

Then to download arangodb now:

 launchctl load ~/Library/LaunchAgents/homebrew.mxcl.arangodb.plist 

Or, if you do not need / need a launch, you can simply run:

 /usr/local/opt/arangodb/sbin/arangod --log.file - 

You should refrain from killing services (be it ArangoDB or anything else) with -9 , unless it is really needed - there will be no clean shutdown, and you may lose data integrity. Dying without a given signal will default to signal 15 ( SIGTERM ), which will cause the service to shut down.

+6
source

I know there is an accepted answer, but the documentation for using homebrew has been updated, and now it is pretty easy:

Initial service

 sudo brew services start arangodb 

Stop service

 sudo brew services stop arangodb 

Reboot service

 sudo brew services restart arangodb 

The configuration file is located in

 /usr/local/etc/arangodb3/arangod.conf 

It is much easier to edit it or change the settings in the plist file located in the arangodb installation.

+4
source

I'm going to:

 jobs -l 

to get the pid of the process. The following are:

 kill -9 <pid> 

to kill the process. The following are:

 /usr/local/sbin/arangod & 

to start the process again.

+2
source

Source: https://habr.com/ru/post/1239679/


All Articles