Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

ExcerptThe This page can now be found at cluster.ini config file, located at /etc/squirro/cluster.ini configures the workings of the Cluster Service that allows to do run Squirro on multiple server.

Table of Contents

Table of Contents
outlinetrue
excludeTable of Contents

Securing the Cluster Service

The Cluster Service manages MySql and Redis Servers thereby keeping the state between multiple Squirro "Cluster Nodes" in sync. To synchronize the MySql Server instances, Squirro leverages MySql replication along with with the following MySql users:

  1. "repl" used to configure and run MySql replication
  2. "cluster" for everything else such as restoring data dumps.
Warning

Note that it is much easier and recommended to set these passwords before configuring a multi-node cluster as changing the password of the repl user on a running cluster is more disruptive. (Instructions for how to change the password of the MySql repl user on a live cluster are in the works, and will likely involve selectively taking nodes out of the cluster one by one.)

 

These two users are configured with a default password which you can configure as follows.

  1. Generate two passwords. Lets refer to the generated passwords as $PASSWORD_REPL and $PASSWORD_CLUSTER
  2. First configure the passwords in /etc/squirro/cluster.ini of all the Squirro "Cluster Nodes" like so:

    Code Block
    title/etc/squirro/cluster.ini
    [mysql]
    db = mysql://cluster:$PASSWORD_CLUSTER@127.0.0.1:3306
    repl_password = $PASSWORD_REPL
  3. On all Squirro "cluster nodes" change the passwords like so:

    Code Block
    languagebash
    sudo su
    mysql -e "SET PASSWORD FOR cluster = PASSWORD(\"$PASSWORD_CLUSTER\")"
    mysql -e "SET PASSWORD FOR repl = PASSWORD(\"$PASSWORD_REPL\")"
  4. Restart the cluster service to pick up the change:

    Code Block
    languagebash
    monit restart sqclusterd

DoneSquirro Docs site.