Configuration

    • Startup options you specify on a command line are referred to as:

    server.database = myDB

    • There are also flags which are for command line usage only,such as ‑‑help and ‑‑version. They don’t take any valuein contrast to options.

    Find the available options and flags in the Options sub-chapters of therespective sub-chapter, like theArangoDB Server Options.

    The works differentlyto the other programs and tools. It uses setup.json files for its ownconfigurationand has a fluent command line interface to execute certain actions.If you deploy ArangoDB with the Starter, then custom arangod.conf filesare generated by this tool and are used instead of the default configuration.

    Command line options can be supplied in the style ‑‑option value with twodashes (also known as hyphen minus), the name of the option, a space asseparator and the value. You may also use an equals sign = as separatorlike ‑‑option=value.

    The value can be surrounded with double quote marks " like‑‑option="value". This is mandatory if the value contains spaces,but it is optional otherwise.

    Some binaries accept one unnamed argument, which means you can take ashortcut and leave out the ‑‑option part and supply the value directly.It does not matter if you supply it as first or last argument, or betweenany of the named arguments. For arangod it is the ‑‑database.directoryoption. The following commands are identical:

    Many options belong to a section as in ‑‑section.param, e.g.‑‑server.database, but there can also be options without any section.These options are referred to as global options.

    To list available options, you can run a binary with the ‑‑help flag:

    1. arangosh --help

    To list the options of a certain section only, use ‑‑help‑{section}like ‑‑help‑server. To list all options including hidden ones use‑‑help‑..

    Configuration file format

    .conf files for ArangoDB binaries are in a simple key-value pair format.Each option is specified on a separate line in the form:

    1. key = value

    It may look like this:

    1. server.endpoint = tcp://127.0.0.1:8529
    2. server.authentication = true
    1. [server]
    2. endpoint = tcp://127.0.0.1:8529
    3. authentication = true

    So you see, a command line option ‑‑section.param value can be easilytranslated to an option in a configuration file:

    1. [section]
    2. param = value

    Whitespace around = is ignored in configuration files.This includes whitespace around equality signs in the parameter value:

    It is the same as without whitespace:

    Comments can be placed in the configuration file by placing one or morehash symbols # at the beginning of a line. Comments that are placed inother places (i.e. not at the beginning of a line) are unsupported and should be avoided to ensure correct parsing of the startup options as intended.

    Only command line options with a value should be set within the configurationfile. Command line options which act as flags should only be entered on thecommand line when starting the server.

    Using Configuration Files

    For each binary (except arangodb, which is the Starter) there is acorresponding .conf file that an ArangoDB package ships with.arangosh.conf contains the default ArangoShell configuration for instance.The configuration files can be adjusted or new ones be created.

    To load a particular configuration file, there is a ‑‑configuration optionavailable to let you specify a path to a .conf file. If you want tocompletely ignore a configuration file (likely the default one) withoutnecessarily deleting the file, then add the command line option

    1. -c none

    or

    1. --configuration none

    The value none is case-insensitive.

    It is possible to add suffixes to numeric options that will cause ArangoDB tomultiply the value by a certain factor. This can be used to conveniently specifyvalues in megabytes or gigabytes for example.

    Suffix could be used like this in a configuration file:

    1. [rocksdb]
    2. write-buffer-size=512KiB
    3. block-cache-size=512MiB
    4. max-bytes-for-level-multiplier=1K
    5. [cache]
    6. size=2G

    Environment variables as parameters

    If you want to use an environment variable in a value of a startup option,write the name of the variable wrapped in at signs @. It acts as aplaceholder. It can be combined with fixed strings for instance.

    1. arangod --temp.path @TEMP@/arango_tmp

    In a configuration file:

    On a Windows system, above setting would typically make the ArangoDB Servercreate its folder for temporary files in %USERPROFILE%\AppData\Local\Temp,i.e. C:\Users\xxx\AppData\Local\Temp\arango_tmp.

    Options with multiple values

    Certain startup options accept multiple values. In case of parameters beingvectors you can specify one or more times the option with varying values.Whether this is the case can be seen by looking at the Type column of atool’s option table (e.g. )or the type information provided on a command line in the —help output ofan ArangoDB binary:

    1. --log.level <string...> the global or topic-specific log level

    Vectors can be identified by the three dots at the end of the data typeinformation (in angled brackets). For log.level you can set one or morestrings for different log levels for example. Simply repeat the option todo so. On a command line:

    1. arangod --log.level warning --log.level queries=trace --log.level startup=info

    This sets a global log level of warning and two topic-specific levels(trace for queries and info for startup). The same in a configuration file:

    1. [log]
    2. level = warning
    3. level = queries=trace
    4. level = startup=info

    There are built-in defaults, with which all configuration variables are firstinitialized. They can be overridden by configuration files and command lineoptions (in this order). Only a fraction of all available options are set inthe configuration files that ArangoDB ships with. Many options will thereforefall back to the built-in defaults unless they are overridden by the user.

    It is common to use modified configuration files together with startupoptions on a command line to override specific settings. Command line optionstake precedence over values set in a configuration file.

    If the same option is set multiple times, but only supports a single value,then the last occurrence of the option will become the final value.For example, if you edit arangosh.conf to set:

    1. server.database = myDB1
    2. server.database = myDB2

    … and start ArangoShell like:

    1. arangosh --server.database myDB3 --server.database myDB4

    … then the database it will connect to is myDB4, because this startup optiontakes a single value only (i.e. it is not a vector), the built-in defaultis _system but the configuration file overrules the setting. It gets set tomyDB1 temporarily before it is replaced by myDB2, which in turn getsoverridden by the command line options twice, first to myDB3 and then thefinal value myDB4.

    Change configuration at runtime

    In general, supplied startup options can not be changed nor can configurationfiles be reloaded once an executable is started, other than by restarting theexecutable with different options. However, some of the startup optionsdefine default values which can be overridden on a per-query basis forinstance, or adjusted at runtime via an API call. Examples:

    Fetch Current Configuration Options

    To list the configuration options of a running instance, you canconnect with an ArangoShell and invoke a by calling db._executeTransaction()and providing a JavaScript function to retrieve the server options:

    Hide execution results

    1. {
    2. "check-configuration" : false,
    3. "config" : "/work/ArangoDB/etc/testing/arangod-single.conf",
    4. "configuration" : "/work/ArangoDB/etc/testing/arangod-single.conf",
    5. "console" : false,
    6. "daemon" : false,
    7. "default-language" : "en_US",
    8. "define" : [
    9. "TOP_DIR=/work/ArangoDB"
    10. ],
    11. "dump-dependencies" : false,
    12. "dump-options" : false,
    13. "fortune" : false,
    14. "gid" : "",
    15. "hund" : false,
    16. "log" : [
    17. "info",
    18. "info",
    19. "replication=warn"
    20. ],
    21. "pid-file" : "",
    22. "supervisor" : false,
    23. "uid" : "",
    24. "version" : false,
    25. "working-directory" : "/var/tmp",
    26. "agency.activate" : false,
    27. "agency.compaction-keep-size" : 50000,
    28. "agency.compaction-step-size" : 1000,
    29. "agency.disaster-recovery-id" : "",
    30. "agency.election-timeout-max" : 5,
    31. "agency.election-timeout-min" : 1,
    32. "agency.endpoint" : [ ],
    33. "agency.max-append-size" : 250,
    34. "agency.my-address" : "",
    35. "agency.pool-size" : 1,
    36. "agency.size" : 1,
    37. "agency.supervision" : false,
    38. "agency.supervision-frequency" : 1,
    39. "agency.supervision-grace-period" : 10,
    40. "agency.wait-for-sync" : true,
    41. "arangosearch.threads" : 0,
    42. "arangosearch.threads-limit" : 0,
    43. "audit.hostname" : "",
    44. "audit.output" : [ ],
    45. "backup.api-enabled" : "true",
    46. "backup.local-path-prefix" : "/",
    47. "cache.rebalancing-interval" : 2000000,
    48. "cache.size" : 16341597184,
    49. "cluster.agency-endpoint" : [ ],
    50. "cluster.agency-prefix" : "",
    51. "cluster.create-waits-for-sync-replication" : false,
    52. "cluster.default-replication-factor" : 1,
    53. "cluster.force-one-shard" : false,
    54. "cluster.index-create-timeout" : 3600,
    55. "cluster.max-number-of-shards" : 1000,
    56. "cluster.max-replication-factor" : 10,
    57. "cluster.min-replication-factor" : 1,
    58. "cluster.my-address" : "",
    59. "cluster.my-advertised-endpoint" : "",
    60. "cluster.my-role" : "",
    61. "cluster.require-persisted-id" : false,
    62. "cluster.resign-leadership-on-shutdown" : false,
    63. "cluster.synchronous-replication-timeout-factor" : 1,
    64. "cluster.synchronous-replication-timeout-minimum" : 30,
    65. "cluster.synchronous-replication-timeout-per-4k" : 0.1,
    66. "cluster.system-replication-factor" : 2,
    67. "cluster.upgrade" : "auto",
    68. "cluster.write-concern" : 1,
    69. "compaction.db-sleep-time" : 1,
    70. "compaction.dead-documents-threshold" : 16384,
    71. "compaction.dead-size-percent-threshold" : 0.1,
    72. "compaction.dead-size-threshold" : 131072,
    73. "compaction.max-file-size-factor" : 3,
    74. "compaction.max-files" : 3,
    75. "compaction.max-result-file-size" : 134217728,
    76. "compaction.min-interval" : 10,
    77. "compaction.min-small-data-file-size" : 131072,
    78. "database.auto-upgrade" : false,
    79. "database.check-version" : false,
    80. "database.force-sync-properties" : false,
    81. "database.ignore-datafile-errors" : false,
    82. "database.init-database" : false,
    83. "database.maximal-journal-size" : 1048576,
    84. "database.required-directory-state" : "any",
    85. "database.restore-admin" : false,
    86. "database.throw-collection-not-loaded-error" : false,
    87. "database.upgrade-check" : true,
    88. "database.wait-for-sync" : false,
    89. "foxx.api" : true,
    90. "foxx.queues" : true,
    91. "foxx.queues-poll-interval" : 1,
    92. "foxx.store" : true,
    93. "frontend.proxy-request-check" : true,
    94. "frontend.trusted-proxy" : [ ],
    95. "frontend.version-check" : true,
    96. "http.allow-method-override" : false,
    97. "http.hide-product-header" : false,
    98. "http.keep-alive-timeout" : 300,
    99. "http.trusted-origin" : [
    100. "*"
    101. ],
    102. "javascript.allow-admin-execute" : true,
    103. "javascript.allow-external-process-control" : false,
    104. "javascript.allow-port-testing" : false,
    105. "javascript.app-path" : "/tmp/arangosh_oLGAal/rocksdb-clusterOrNot/apps",
    106. "javascript.copy-installation" : false,
    107. "javascript.enabled" : true,
    108. "javascript.endpoints-blacklist" : [ ],
    109. "javascript.endpoints-whitelist" : [ ],
    110. "javascript.environment-variables-blacklist" : [ ],
    111. "javascript.environment-variables-whitelist" : [ ],
    112. "javascript.files-whitelist" : [ ],
    113. "javascript.gc-frequency" : 60,
    114. "javascript.gc-interval" : 2000,
    115. "javascript.harden" : false,
    116. "javascript.module-directory" : [
    117. "/work/ArangoDB/enterprise/js"
    118. ],
    119. "javascript.script" : [ ],
    120. "javascript.script-parameter" : [ ],
    121. "javascript.startup-directory" : "/work/ArangoDB/js",
    122. "javascript.startup-options-blacklist" : [ ],
    123. "javascript.startup-options-whitelist" : [ ],
    124. "javascript.v8-contexts" : 16,
    125. "javascript.v8-contexts-max-age" : 60,
    126. "javascript.v8-contexts-max-invocations" : 0,
    127. "javascript.v8-contexts-minimum" : 1,
    128. "javascript.v8-max-heap" : 3072,
    129. "javascript.v8-options" : [ ],
    130. "ldap.async-connect" : false,
    131. "ldap.basedn" : "",
    132. "ldap.binddn" : "",
    133. "ldap.debug" : false,
    134. "ldap.enabled" : false,
    135. "ldap.network-timeout" : 0,
    136. "ldap.port" : 389,
    137. "ldap.prefix" : "",
    138. "ldap.referrals" : false,
    139. "ldap.refresh-rate" : 300,
    140. "ldap.restart" : false,
    141. "ldap.retries" : 1,
    142. "ldap.roles-attribute-name" : "",
    143. "ldap.roles-exclude" : "",
    144. "ldap.roles-include" : "",
    145. "ldap.roles-search" : "",
    146. "ldap.roles-transformation" : [ ],
    147. "ldap.search-attribute" : "uid",
    148. "ldap.search-filter" : "objectClass=*",
    149. "ldap.search-scope" : "sub",
    150. "ldap.serialize-timeout" : 5,
    151. "ldap.serialized" : false,
    152. "ldap.server" : "",
    153. "ldap.suffix" : "",
    154. "ldap.superuser-role" : "",
    155. "ldap.timeout" : 0,
    156. "ldap.tls" : false,
    157. "ldap.tls-cacert-dir" : "",
    158. "ldap.tls-cacert-file" : "",
    159. "ldap.tls-cert-check-strategy" : "hard",
    160. "ldap.tls-version" : "1.2",
    161. "ldap.url" : "",
    162. "log.color" : true,
    163. "log.escape" : true,
    164. "log.file" : "/tmp/arangosh_oLGAal/rocksdb-clusterOrNot/log",
    165. "log.file-group" : "",
    166. "log.file-mode" : "",
    167. "log.force-direct" : false,
    168. "log.foreground-tty" : false,
    169. "log.ids" : true,
    170. "log.keep-logrotate" : false,
    171. "log.level" : [
    172. "info",
    173. "info",
    174. "replication=warn"
    175. ],
    176. "log.line-number" : false,
    177. "log.output" : [
    178. "file:///tmp/arangosh_oLGAal/rocksdb-clusterOrNot/log"
    179. ],
    180. "log.performance" : false,
    181. "log.prefix" : "",
    182. "log.request-parameters" : true,
    183. "log.role" : true,
    184. "log.shorten-filenames" : true,
    185. "log.thread" : false,
    186. "log.thread-name" : false,
    187. "log.time-format" : "utc-datestring",
    188. "log.use-local-time" : false,
    189. "log.use-microtime" : false,
    190. "network.idle-connection-ttl" : 60000,
    191. "network.io-threads" : 1,
    192. "network.max-open-connections" : 1024,
    193. "network.verify-hosts" : false,
    194. "nonce.size" : 4194304,
    195. "query.cache-entries" : 128,
    196. "query.cache-entries-max-size" : 268435456,
    197. "query.cache-entry-max-size" : 16777216,
    198. "query.cache-include-system-collections" : false,
    199. "query.cache-mode" : "off",
    200. "query.fail-on-warning" : false,
    201. "query.memory-limit" : 0,
    202. "query.optimizer-max-plans" : 128,
    203. "query.parallelize-gather-writes" : true,
    204. "query.registry-ttl" : 30,
    205. "query.slow-streaming-threshold" : 10,
    206. "query.slow-threshold" : 10,
    207. "query.smart-joins" : true,
    208. "query.tracking" : true,
    209. "query.tracking-with-bindvars" : true,
    210. "random.generator" : 1,
    211. "rclone.executable" : "rclone-arangodb",
    212. "replication.active-failover" : false,
    213. "replication.auto-start" : true,
    214. "replication.automatic-failover" : false,
    215. "replication.connect-timeout" : 10,
    216. "replication.max-parallel-tailing-invocations" : 0,
    217. "replication.request-timeout" : 600,
    218. "rocksdb.allow-fallocate" : true,
    219. "rocksdb.block-align-data-blocks" : false,
    220. "rocksdb.block-cache-shard-bits" : -1,
    221. "rocksdb.block-cache-size" : 19609916620,
    222. "rocksdb.compaction-read-ahead-size" : 2097152,
    223. "rocksdb.create-sha-files" : true,
    224. "rocksdb.debug-logging" : false,
    225. "rocksdb.delayed-write-rate" : 0,
    226. "rocksdb.dynamic-level-bytes" : true,
    227. "rocksdb.enable-pipelined-write" : false,
    228. "rocksdb.enable-statistics" : false,
    229. "rocksdb.encryption-key-generator" : "",
    230. "rocksdb.encryption-keyfile" : "",
    231. "rocksdb.enforce-block-cache-size-limit" : false,
    232. "rocksdb.exclusive-writes" : false,
    233. "rocksdb.intermediate-commit-count" : 1000000,
    234. "rocksdb.intermediate-commit-size" : 536870912,
    235. "rocksdb.level0-compaction-trigger" : 2,
    236. "rocksdb.level0-slowdown-trigger" : 20,
    237. "rocksdb.level0-stop-trigger" : 36,
    238. "rocksdb.limit-open-files-at-startup" : false,
    239. "rocksdb.max-background-jobs" : 8,
    240. "rocksdb.max-bytes-for-level-base" : 268435456,
    241. "rocksdb.max-bytes-for-level-multiplier" : 10,
    242. "rocksdb.max-subcompactions" : 0,
    243. "rocksdb.max-total-wal-size" : 83886080,
    244. "rocksdb.max-transaction-size" : 18446744073709552000,
    245. "rocksdb.max-write-buffer-number" : 9,
    246. "rocksdb.min-write-buffer-number-to-merge" : 1,
    247. "rocksdb.num-levels" : 7,
    248. "rocksdb.num-threads-priority-high" : 4,
    249. "rocksdb.num-threads-priority-low" : 4,
    250. "rocksdb.num-uncompressed-levels" : 2,
    251. "rocksdb.optimize-filters-for-hits" : false,
    252. "rocksdb.recycle-log-file-num" : false,
    253. "rocksdb.sync-interval" : 100,
    254. "rocksdb.table-block-size" : 16384,
    255. "rocksdb.throttle" : true,
    256. "rocksdb.total-write-buffer-size" : 26146555494,
    257. "rocksdb.transaction-lock-timeout" : 1000,
    258. "rocksdb.use-direct-io-for-flush-and-compaction" : false,
    259. "rocksdb.use-direct-reads" : false,
    260. "rocksdb.use-file-logging" : false,
    261. "rocksdb.use-fsync" : false,
    262. "rocksdb.wal-archive-size-limit" : 0,
    263. "rocksdb.wal-directory" : "",
    264. "rocksdb.wal-file-timeout" : 10,
    265. "rocksdb.wal-file-timeout-initial" : 180,
    266. "rocksdb.wal-recovery-skip-corrupted" : false,
    267. "rocksdb.write-buffer-size" : 67108864,
    268. "server.allow-use-database" : true,
    269. "server.authentication" : false,
    270. "server.authentication-system-only" : true,
    271. "server.authentication-timeout" : 0,
    272. "server.authentication-unix-sockets" : true,
    273. "server.check-max-memory-mappings" : true,
    274. "server.descriptors-minimum" : 0,
    275. "server.endpoint" : [
    276. "tcp://127.0.0.1:3492"
    277. ],
    278. "server.export-metrics-api" : true,
    279. "server.flush-interval" : 1000000,
    280. "server.gid" : "",
    281. "server.harden" : false,
    282. "server.io-threads" : 8,
    283. "server.local-authentication" : true,
    284. "server.maintenance-actions-block" : 2,
    285. "server.maintenance-actions-linger" : 3600,
    286. "server.maintenance-threads" : 9,
    287. "server.maximal-queue-size" : 4096,
    288. "server.maximal-threads" : 64,
    289. "server.minimal-threads" : 2,
    290. "server.prio1-size" : 4096,
    291. "server.rest-server" : true,
    292. "server.scheduler-queue-size" : 4096,
    293. "server.statistics" : true,
    294. "server.statistics-history" : true,
    295. "server.storage-engine" : "rocksdb",
    296. "server.uid" : "",
    297. "ssl.cafile" : "",
    298. "ssl.cipher-list" : "HIGH:!EXPORT:!aNULL@STRENGTH",
    299. "ssl.ecdh-curve" : "prime256v1",
    300. "ssl.keyfile" : "/work/ArangoDB/UnitTests/server.pem",
    301. "ssl.options" : 2147485780,
    302. "ssl.protocol" : 9,
    303. "ssl.require-peer-certificate" : false,
    304. "ssl.session-cache" : false,
    305. "tcp.backlog-size" : 64,
    306. "tcp.reuse-address" : true,
    307. "temp.path" : "/tmp/arangosh_oLGAal/rocksdb-clusterOrNot/tmp",
    308. "ttl.frequency" : 30000,
    309. "ttl.max-collection-removes" : 1000000,
    310. "ttl.max-total-removes" : 1000000,
    311. "ttl.only-loaded-collection" : true,
    312. "wal.allow-oversize-entries" : true,
    313. "wal.directory" : "",
    314. "wal.flush-timeout" : 30000,
    315. "wal.historic-logfiles" : 10,
    316. "wal.ignore-logfile-errors" : false,
    317. "wal.ignore-recovery-errors" : false,
    318. "wal.logfile-size" : 33554432,
    319. "wal.open-logfiles" : 0,
    320. "wal.reserve-logfiles" : 3,
    321. "wal.slots" : 1048576,
    322. "wal.sync-interval" : 100000,
    323. "wal.throttle-wait" : 15000,
    324. "wal.throttle-when-pending" : 0,
    325. "wal.use-mlock" : false