I am evaluation ArangoDB and figured there are at least 3 ways to start the DB.
This is all very confusing, can someone provide visibility about the different options and what is the best way to start the engine.
Thank you
These are not different ways to start Arango. These are different tools that can be used with Arango
arangosh is a shell tool that an be used to administer the DB as well as running ad-hoc queries. It does not start a server, it only starts the shell that connects to a server
arangod : This is the deamon that runs when you start Arangodb. In fact, to start the server you usually run (at least on Mac) /usr/local/Cellar/arangodb/3.4.0/sbin/arangod
arangodb : This is the db install package. For example, in the Mac you would run brew install arangodb
to install arangodb on your machine
arangocli: This is simply a cli tool to run ad-hoc queries.
arangod
starts a single ArangoDB server, which is sufficient to run a Single Instance deployment. To run more complex deployments (eg Cluster, Active Failover) multiple arangod
processes are required.
For example a Cluster with 3 agents, 2 dbservers and 2 coordinators requires 8 arangod
processes in total. More can be found in the Cluster - Manual Start documentation.
In order to simplify the deployment it is recommended to use the arangodb
starter tool. The execution of arangodb
initializes an arangod
process for each dbserver, coordinator and agent. Eg using arangodb --starter.local
to start a local 3 node cluster starts 9 arangod
processes internally: 3 dbservers, 3 coordinators and 3 agents. The running arangod
processes can be checked with ps auxw | grep arangod
ps auxw | grep arangod
.
An exemplary output can be seen below:
ps auxw | grep arangod
max 8099 1.9 0.1 114712 8736 pts/0 Sl+ 14:47 0:00 arangodb --starter.local
max 8118 3.9 2.5 635016 203736 pts/0 Sl+ 14:47 0:00 /usr/sbin/arangod -c /home/max/Documents/starter/test/local-slave-2/agent8551/arangod.conf --database.directory /home/max/Documents/starter/test/local-slave-2/agent8551/data --javascript.startup-directory /usr/share/arangodb3/js --javascript.app-path /home/max/Documents/starter/test/local-slave-2/agent8551/apps --log.file /home/max/Documents/starter/test/local-slave-2/agent8551/arangod.log --log.force-direct false --javascript.copy-installation true --agency.activate true --agency.my-address tcp://localhost:8551 --agency.size 3 --agency.supervision true --foxx.queues false --server.statistics false --agency.endpoint tcp://localhost:8531 --agency.endpoint tcp://localhost:8541
max 8165 10.5 2.6 676548 215908 pts/0 Sl+ 14:47 0:01 /usr/sbin/arangod -c /home/max/Documents/starter/test/agent8531/arangod.conf --database.directory /home/max/Documents/starter/test/agent8531/data --javascript.startup-directory /usr/share/arangodb3/js --javascript.app-path /home/max/Documents/starter/test/agent8531/apps --log.file /home/max/Documents/starter/test/agent8531/arangod.log --log.force-direct false --javascript.copy-installation true --agency.activate true --agency.my-address tcp://localhost:8531 --agency.size 3 --agency.supervision true --foxx.queues false --server.statistics false --agency.endpoint tcp://localhost:8541 --agency.endpoint tcp://localhost:8551
max 8168 5.4 2.6 705236 216828 pts/0 Sl+ 14:47 0:00 /usr/sbin/arangod -c /home/max/Documents/starter/test/local-slave-2/dbserver8550/arangod.conf --database.directory /home/max/Documents/starter/test/local-slave-2/dbserver8550/data --javascript.startup-directory /usr/share/arangodb3/js --javascript.app-path /home/max/Documents/starter/test/local-slave-2/dbserver8550/apps --log.file /home/max/Documents/starter/test/local-slave-2/dbserver8550/arangod.log --log.force-direct false --javascript.copy-installation true --cluster.my-address tcp://localhost:8550 --cluster.my-role PRIMARY --foxx.queues false --server.statistics true --cluster.agency-endpoint tcp://localhost:8531 --cluster.agency-endpoint tcp://localhost:8541 --cluster.agency-endpoint tcp://localhost:8551
max 8171 4.8 2.5 641160 204968 pts/0 Sl+ 14:47 0:00 /usr/sbin/arangod -c /home/max/Documents/starter/test/local-slave-1/agent8541/arangod.conf --database.directory /home/max/Documents/starter/test/local-slave-1/agent8541/data --javascript.startup-directory /usr/share/arangodb3/js --javascript.app-path /home/max/Documents/starter/test/local-slave-1/agent8541/apps --log.file /home/max/Documents/starter/test/local-slave-1/agent8541/arangod.log --log.force-direct false --javascript.copy-installation true --agency.activate true --agency.my-address tcp://localhost:8541 --agency.size 3 --agency.supervision true --foxx.queues false --server.statistics false --agency.endpoint tcp://localhost:8531 --agency.endpoint tcp://localhost:8551
max 8302 6.4 2.6 696532 216668 pts/0 Sl+ 14:47 0:00 /usr/sbin/arangod -c /home/max/Documents/starter/test/dbserver8530/arangod.conf --database.directory /home/max/Documents/starter/test/dbserver8530/data --javascript.startup-directory /usr/share/arangodb3/js --javascript.app-path /home/max/Documents/starter/test/dbserver8530/apps --log.file /home/max/Documents/starter/test/dbserver8530/arangod.log --log.force-direct false --javascript.copy-installation true --cluster.my-address tcp://localhost:8530 --cluster.my-role PRIMARY --foxx.queues false --server.statistics true --cluster.agency-endpoint tcp://localhost:8531 --cluster.agency-endpoint tcp://localhost:8541 --cluster.agency-endpoint tcp://localhost:8551
max 8304 26.7 2.4 744684 199052 pts/0 Sl+ 14:47 0:02 /usr/sbin/arangod -c /home/max/Documents/starter/test/local-slave-2/coordinator8549/arangod.conf --database.directory /home/max/Documents/starter/test/local-slave-2/coordinator8549/data --javascript.startup-directory /usr/share/arangodb3/js --javascript.app-path /home/max/Documents/starter/test/local-slave-2/coordinator8549/apps --log.file /home/max/Documents/starter/test/local-slave-2/coordinator8549/arangod.log --log.force-direct false --javascript.copy-installation true --cluster.my-address tcp://localhost:8549 --cluster.my-role COORDINATOR --foxx.queues true --server.statistics true --cluster.agency-endpoint tcp://localhost:8531 --cluster.agency-endpoint tcp://localhost:8541 --cluster.agency-endpoint tcp://localhost:8551
max 8306 5.8 2.6 711380 215200 pts/0 Sl+ 14:47 0:00 /usr/sbin/arangod -c /home/max/Documents/starter/test/local-slave-1/dbserver8540/arangod.conf --database.directory /home/max/Documents/starter/test/local-slave-1/dbserver8540/data --javascript.startup-directory /usr/share/arangodb3/js --javascript.app-path /home/max/Documents/starter/test/local-slave-1/dbserver8540/apps --log.file /home/max/Documents/starter/test/local-slave-1/dbserver8540/arangod.log --log.force-direct false --javascript.copy-installation true --cluster.my-address tcp://localhost:8540 --cluster.my-role PRIMARY --foxx.queues false --server.statistics true --cluster.agency-endpoint tcp://localhost:8531 --cluster.agency-endpoint tcp://localhost:8541 --cluster.agency-endpoint tcp://localhost:8551
max 8318 27.5 2.5 760064 202456 pts/0 Sl+ 14:47 0:02 /usr/sbin/arangod -c /home/max/Documents/starter/test/coordinator8529/arangod.conf --database.directory /home/max/Documents/starter/test/coordinator8529/data --javascript.startup-directory /usr/share/arangodb3/js --javascript.app-path /home/max/Documents/starter/test/coordinator8529/apps --log.file /home/max/Documents/starter/test/coordinator8529/arangod.log --log.force-direct false --javascript.copy-installation true --cluster.my-address tcp://localhost:8529 --cluster.my-role COORDINATOR --foxx.queues true --server.statistics true --cluster.agency-endpoint tcp://localhost:8531 --cluster.agency-endpoint tcp://localhost:8541 --cluster.agency-endpoint tcp://localhost:8551
max 8321 32.8 2.5 764160 202212 pts/0 Sl+ 14:47 0:02 /usr/sbin/arangod -c /home/max/Documents/starter/test/local-slave-1/coordinator8539/arangod.conf --database.directory /home/max/Documents/starter/test/local-slave-1/coordinator8539/data --javascript.startup-directory /usr/share/arangodb3/js --javascript.app-path /home/max/Documents/starter/test/local-slave-1/coordinator8539/apps --log.file /home/max/Documents/starter/test/local-slave-1/coordinator8539/arangod.log --log.force-direct false --javascript.copy-installation true --cluster.my-address tcp://localhost:8539 --cluster.my-role COORDINATOR --foxx.queues true --server.statistics true --cluster.agency-endpoint tcp://localhost:8531 --cluster.agency-endpoint tcp://localhost:8541 --cluster.agency-endpoint tcp://localhost:8551
When specifying an option with the starter arangodb
as --server.storage-engine rocksdb
, this option is passed to all the starter's arangod
processes.
A detailed overview for various deployment modes can be found in the documentation's Deployment chapter.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.