Emergency Console

The ArangoDB database server has two modes of operation: As a server, where itwill answer to client requests and as an emergency console, in which you canaccess the database directly. The latter - as the name suggests - shouldonly be used in case of an emergency, for example, a corruptedcollection. Using the emergency console allows you to issue all commandsnormally available in actions and transactions. When starting the server inemergency console mode, the server cannot handle any client requests.

You should never start more than one server using the same database directory,independent of the mode of operation. Normally, ArangoDB will preventyou from doing this by placing a lockfile in the database directory andnot allowing a second ArangoDB instance to use the same database directoryif a lockfile is already present.

In Case Of Disaster

The following command starts an emergency console.

Note: Never start the emergency console for a database which also has aserver attached to it. In general, the ArangoDB shell is what you want.

  1. > ./arangod --console --log error /tmp/vocbase
  2. ArangoDB shell [V8 version 5.0.71.39, DB version 3.x.x]
  3. arango> 1 + 2;
  4. 3
  5. arango> var db = require("@arangodb").db; db.geo.count();
  6. 703

The emergency console provides a JavaScript console directly running in thearangod server process. This allows to debug and examine collections anddocuments as with the normal ArangoDB shell, but without client/servercommunication.

However, it is very likely that you will never need the emergency consoleunless you are an ArangoDB developer.