New install with playbooks#

Important

For instructions to upgrade an existing installation, see Upgrade with playbooks instead.

Requirements#

You must:

  • Have already completed Prepare nodes.

  • Run the playbooks here in sequence.

Tip

A playbook run is successful if has 0 failed tasks.

The following is an example PLAY RECAP from a successful (failed=0) single node playbook run:

PLAY RECAP ******************************************************************************************
application-node           : ok=64   changed=44   unreachable=0    failed=0    skipped=12   rescued=0    ignored=0   
localhost                  : ok=1    changed=0    unreachable=0    failed=0    skipped=0    rescued=0    ignored=0   

Run the playbooks#

Caution

You may have used an .envrc file in earlier versions of the installation playbooks. Rename it to .env, or create an .env file using instructions in Set up .env.

On the control node, run playbooks with the ansible-playbook command with these command line options:

ansible-playbook --tags=all,logstash -i inventories/<inventory_file.yml> <pb-playbook.yml>

Option

Description

--tags=all,logstash

(Optional) Use --tags=all,logstash to include Logstash. You can omit this option entirely to install EclecticIQ Intelligence Center without Logstash.

-i inventories/<inventory_file.yml>

Specify the path to an inventory file configured for your deployment.

Inventory files are described in Prepare nodes.

<pb-playbook.yml>

This is the playbook to run.

Run the playbooks in this sequence:

Tip

Playbooks here are idempotent. Repeated runs have no effect.

If there is nothing for a playbook to do (e.g. tasks do not apply to deployment type), running it has no effect.

  1. Load .env. Run:

    source .env
    
  2. Prepare nodes: pb-pre_requisites.yml

    ansible-playbook --tags=all,logstash -i inventories/<inventory_file.yml> pb-pre_requisites.yml
    
  3. Install foundation and base roles: pb-install-foundations-and-base.yml

    ansible-playbook --tags=all,logstash -i inventories/<inventory_file.yml> pb-install-foundations-and-base.yml
    
  4. Run Elasticsearch upgrade and data migration: pb-es-upgrade-data.yml

    ansible-playbook --tags=all,logstash -i inventories/<inventory_file.yml> pb-es-upgrade-data.yml
    
  5. Install components: pb-install_intelligence_center.yml

    ansible-playbook --tags=all,logstash -i inventories/<inventory_file.yml> pb-install_intelligence_center.yml
    
  6. Run PostgreSQL upgrade: pb-pg_upgrade.yml

    ansible-playbook --tags=all,logstash -i inventories/<inventory_file.yml> pb-pg_upgrade.yml
    
  7. Make sure services have started: pb-start_services.yml

    ansible-playbook --tags=all,logstash -i inventories/<inventory_file.yml> pb-start_services.yml
    
  8. Run database migrations: pb-migrate_databases.yml

    ansible-playbook --tags=all,logstash -i inventories/<inventory_file.yml> pb-migrate_databases.yml
    
  9. Start services: pb-start_services.yml

    ansible-playbook --tags=all,logstash -i inventories/<inventory_file.yml> pb-start_services.yml
    
  10. Run the post-installation playbook: pb-post.yml

    ansible-playbook --tags=all,logstash -i inventories/<inventory_file.yml> pb-post.yml
    
  11. Reboot your managed node(s) after pb-post.yml completes.

New install with multi-node PostgreSQL#

To initialize replicas in a PostgreSQL cluster, run the PostgreSQL replication playbook:

Danger

This purges data from all PostgreSQL nodes set in your inventory file with the property: eiq_ic_pg_replication__node_role: replica

  1. Initialize replication: pb-pg_start_replication.yml

    ansible-playbook --tags=all,logstash -i inventories/<inventory_file.yml> pb-pg_start_replication.yml
    
  2. Then make sure all services are running: pb-start_services.yml

    ansible-playbook --tags=all,logstash -i inventories/<inventory_file.yml> pb-start_services.yml