Getting Started (Short Version)

edit

The following tutorial will get you up and running with Shield in 2 minutes.

Assumptions

edit
  • You have Java™ 7 or above installed.
  • You have downloaded Elasticsearch 1.4.2 (or a newer version of Elasticsearch 1.4.x) and extracted it (from now on, we’ll refer to the Elasticsearch directory as ES_HOME). If you haven’t done so, you can download Elasticsearch 1.4.5 here.
  • You are not using a package installation (RPM/DEB) or a custom configuration directory. If you are, please see the full getting started guide.

Installation

edit
  1. cd to ES_HOME
  2. Install the license plugin

    bin/plugin -i elasticsearch/license/latest
  3. Next, install the shield plugin

    bin/plugin -i elasticsearch/shield/latest
  4. Start Elasticsearch

    bin/elasticsearch
  5. Add a es_admin user with administrative permissions

    bin/shield/esusers useradd es_admin -r admin
  6. Try it out - without username/password, the request should be rejected:

    curl -XGET 'http://localhost:9200/'
  7. Now try with username and password

    curl -u es_admin -XGET 'http://localhost:9200/'
  8. Optionally, verify the Shield version

    curl -u es_admin -XGET 'http://localhost:9200/_shield'

Next Steps

edit
  • For a more in-depth look into the meaning of each step above, please proceed to the full getting started guide.
  • For better understanding of the authentication mechanisms we just used, please refer to esusers - internal file based authentication
  • To learn about how to create roles and customize the permissions for users, please refer to the authorization section.
  • To enable secure SSL/TLS encryption of cluster and client communication, please refer to the securing nodes section.
  • If you are new to Shield, we suggest following the guide’s natural path and reading each section in order. To continue, proceed to the next section