AEROSPIKE README
================

SYNOPSIS

  ./bin/aerospike init
  sudo ./bin/aerospike start
  ./bin/aerospike status
  ./bin/aerospike stop

DESCRIPTION

  This package contains the Aerospike Server Daemon (asd), scripts,
  configuration files, and other resources.

QUICK START

  The `aerospike` script, located in the `bin` directory, provides the ability
  to initialize a directory for running `asd` and managing an instance of `asd`
  from that directory.

  The following is a quick walk-through to help you get started:

    1. Initialize a directory for hosting your aerospike instance.

        ./bin/aerospike init

    2. Start the aerospike server

        sudo ./bin/aerospike start

      Superuser privileges are required because it attempts to set upper
      limits on system resources.

    3. Check the status of the aerospike server

        ./bin/aerospike status

    4. Stop the aerospike server

        sudo ./bin/aerospike stop


AEROSPIKE SCRIPT

  The `aerospike` script, located in the `bin` directory, provides the ability
  to managing an instance of `asd`.

  For help with the script, use the `--help` option:

      ./bin/aerospike --help 

AEROSPIKE INSTANCE DIRECTORY
  
  The directory created by the `aerospike init` command will contain:

    bin/aerospike         - The management script to manage this instance.
    bin/asd               - The aerospike server daemon.
    etc/aerospike.conf    - The configuration file used by this instance.
    share/                - Contains read-only files, used by this instance.
    var/                  - Contains runtime files generated by `asd`, including
                            logs and data files.

NOTES

  1. The `aerospike init` script can be used to initialize any directory to host
    an aerospike instance by specifying the `--home <PATH>` option

        ./bin/aerospike init --home ~/myaerospike

    For running multiple instances, see below.

  2. Running Multiple Instances

    NOTE: For production environments, it is not recommended to run multiple
    instances on a single host. The reason is that you would ideally allocate
    as many resource as possible to a production instance.

    If you want to run multiple instances of aerospike on a single machine, then
    each instance should be initialized with different instance id and port
    number. The default instance id is "1" and the default port is "3000".

    To initialize two instances, you can use:

        ./bin/aerospike init --home ~/a --instance 1 -p 3000
        ./bin/aerospike init --home ~/b --instance 2 -p 3010

    The aerospike.conf for each instance cannot share resources. If you
    define storage engines other than in-memory, then each must have dedicated
    resources (file, device, etc) dedicated to those instance. There is
    a limit of 15 possible instances which can created.

  3. Running as non-root Users

    If you want to run instances of aerospike as non-root users, you can provide
    the user and group ids during initialization time:

        ./bin/aerospike init --home ~/aerobob --user bob --group bobs

    This will initialize setup the home directory to be owned by "bob". Also,
    the server will run as the user "bob".
