CLI tools

    If your working directory is , you can run an executable like this:

    Otherwise, you can run:

    1. sh$ <PATH_TO_CRATE_HOME>/bin/crate

    Here, replace <PATH_TO_CRATE_HOME> with a path to CRATE_HOME.

    Alternatively, if the CrateDB bin directory is on your , you can run an executable directly:

    Table of contents

    The crate executable runs the CrateDB daemon.

    See also

    This section is a low-level command reference. For help installing CrateDB for the first time, check out the CrateDB installation tutorial. Alternatively, consult the for help running CrateDB in production.

    1. sh$ bin/crate [-dhvCDX] [-p <PID_FILE>]

    Options

    The CrateDB process can handle the following signals.

    Tip

    The TERM signal stops CrateDB immediately. As a result, pending requests may fail. To ensure that CrateDB finishes handling pending requests before the node is stopped, you can, instead, perform a with the DECOMMISSION statement.

    The simplest way to start a CrateDB instance is to invoke crate without parameters:

    This command starts the process in the foreground.

    You can also start CrateDB in the background with the -d option. When doing this, it’s helpful to write the process ID (PID) to a PID file with the -p option. So, in combination:

    1. sh$ bin/crate -d -p crate.pid

    To stop the process, send a TERM signal using the PID file, like so:

    The crate-node executable is a tool that can help you:

    See also

    This section is a low-level command reference. For help using crate-node, consult the .

    1. sh$ bin/crate-node repurpose|unsafe-bootstrap|detach-cluster
    2. [--ordinal <INT>] [-E <KV_PAIR>]

    Commands