ArangoDB v3.11 reached End of Life (EOL) and is no longer supported.

This documentation is outdated. Please see the most recent stable version.

The ArangoDB exit codes and their meanings

The ArangoDB server and the client tools set a number called exit code when they terminate, and you can look up what they mean here

Exit codes

Exit codes are numeric values programs return when they finish, indicating success or failure.

  • An exit code of zero indicates a successful execution, e.g. the termination of the server process without without any issues.
  • Any non-zero exit code indicates that some error occurred, e.g. you tried to run a program with invalid parameters or it failed to process something.

Right after running a command in a command-line, you can show the exit code like so:

  • Bash, zsh, and other shells: echo $?
  • Fish shell: echo $status
  • PowerShell: echo $LASTEXITCODE

The ArangoDB server and (to some extent) the client tools use exit codes to signal to other applications or the operating system whether they encountered problems. You can typically tell from the log messages right before the process termination what errors were encountered, but in certain cases you might only have the exit code. The below list of exit codes can help you understand the cause in such a case.

List of exit codes

The following exit codes are used by the ArangoDB server (arangod), the ArangoDB Shell (arangosh), arangodump, arangorestore, arangoimport, arangoexport, arangobench, arangovpack, and arangoinspect.

They are grouped into a few categories. There is a headline for each exit code with the format code - name, and the exit code description as the text.

General

0 - EXIT_SUCCESS

No error has occurred.

1 - EXIT_FAILED

Will be returned when a general error occurred.

2 - EXIT_CODE_RESOLVING_FAILED

unspecified exit code

3 - EXIT_INVALID_OPTION_NAME

invalid/unknown startup option name was used

4 - EXIT_INVALID_OPTION_VALUE

invalid startup option value was used

5 - EXIT_BINARY_NOT_FOUND

Will be returned if a referenced binary was not found

6 - EXIT_CONFIG_NOT_FOUND

Will be returned if no valid configuration was found or its contents are structurally invalid

Internal

10 - EXIT_UPGRADE_FAILED

Will be returned when the database upgrade failed

11 - EXIT_UPGRADE_REQUIRED

Will be returned when a database upgrade is required

12 - EXIT_DOWNGRADE_REQUIRED

Will be returned when a database upgrade is required

13 - EXIT_VERSION_CHECK_FAILED

Will be returned when there is a version mismatch

Startup

20 - EXIT_ALREADY_RUNNING

Will be returned when arangod is already running according to PID-file

21 - EXIT_COULD_NOT_BIND_PORT

Will be returned when the configured tcp endpoint is already occupied by another process

22 - EXIT_COULD_NOT_LOCK

Will be returned if another ArangoDB process is running, or the state can not be cleared

23 - EXIT_RECOVERY

Will be returned if the automatic database startup recovery fails

24 - EXIT_DB_NOT_EMPTY

Will be returned when commanding to initialize a non empty directory as database

25 - EXIT_UNSUPPORTED_STORAGE_ENGINE

Will be returned when trying to start with an unsupported storage engine

26 - EXIT_ICU_INITIALIZATION_FAILED

Will be returned if icudtl.dat is not found, of the wrong version or invalid. Check for an incorrectly set ICU_DATA environment variable

27 - EXIT_TZDATA_INITIALIZATION_FAILED

Will be returned if tzdata is not found

28 - EXIT_RESOURCES_TOO_LOW

Will be returned if i.e. ulimit is too restrictive

29 - EXIT_SST_FILE_CHECK

Will be returned when either sst file open or sst file check was unsuccessful i.e. sst file is not valid