Plixer Replicator

When Plixer Replicator is deployed as part of a distributed environment, Plixer Scrutinizer can leverage the Auto-Replicate feature to automatically assign exporters to collectors based on their capacities and current workloads. With Auto-Replicate enabled, all exporters can be configured to send flows to Plixer Replicator, and replication profiles are automatically created for all collectors in the distributed cluster.

Note

See this section of the FAQ or the Plixer Replicator online documentation to learn more about Plixer Replicator’s functions. For information on licensing options, contact Plixer Technical Support.

Setting up auto-replication on Plixer Scrutinizer is divided into three main processes:

Creating the seed profile

The seed profile on the Plixer Replicator instance functions as a list of exporters that Plixer Scrutinizer should add to the auto-replication profiles it maintains.

The seed profile can be created as follows:

  1. Deploy the Plixer Replicator instance and complete the basic configuration steps as described here.

  2. Create a new profile to use as the seed profile (or use the profile that was created during the basic configuration process).

  3. Add a policy to include all exporters to the profile.

  4. [Optional] If there are exporters whose flows should not be auto-replicated, add policies to exclude those exporters to the profile.

Once the seed profile has been set up, it will need to be registered with Plixer Scrutinizer to complete the auto-replication configuration.

Registering the seed profile

After the seed profile is created on Plixer Replicator, log in to Plixer Scrutinizer and register the profile as follows:

  1. In the Plixer Scrutinizer web interface, navigate to Admin > Plixer > Plixer Replicator.

  2. Fill in the form with the following details:

    • replicator user password

    • Listening/in port (for receiving flows) on the Plixer Replicator instance

    • IP address or hostname of Plixer Replicator instance (must start with https://)

    • Name of the seed profile created for auto-replication

    • Sending/out port (for replicated flows) on the Plixer Replicator instance

  3. Tick the Enable checkbox, and then click the Save button to save the seed profile configuration.

  4. After the seed profile has been registered, SSH to the distributed cluster’s primary reporter as the plixer user.

  5. Run the following command once to create the auto-replication configuration file:

    scrut_util --autoreplicate
    

Running scrut_util --autoreplicate for the first time will create /home/plixer/scrutinizer/files/autoreplicate.conf, where individual collector properties and additional auto-replication settings can be configured.

Note

  • Because Plixer Scrutinizer manages exporter-to-collector assignments for auto-replication, the seed profile should not have a collector defined.

  • If additional devices are deployed to the environment, scrut_util --autoreplicate should be run again to update Plixer Scrutinizer’s list of auto-replication exporters.

  • Instead of using a policy to include all exporters in an environment, devices can also be added individually to the seed profile. In such cases, the seed profile should be updated before running scrut_util --autoreplicate again, when additional exporters are deployed.

Editing the configuration file

After the autoreplicate.conf file has been created, it should be reviewed and edited to configure the parameters Plixer Scrutinizer will use to manage auto-replication.

Afterwards, scrut_util --autoreplicate should be run a second time to start the auto-replication service.

Note

  • Any time the configuration file is modified in any way, scrut_util --autoreplicate should be run again to update Plixer Scrutinizer’s auto-replication configuration.

  • The --verbose flag can also be added to verify that the correct auto-replication settings have been applied in Plixer Scrutinizer.

  • Once auto-replication is active, Plixer Scrutinizer will only reassign an exporter if its current collector exceeds the configured exporter or flow rate capacity. Setting up a cronjob to run scrut_util --autoreplicate at regular intervals can help maintain a balanced load across available collectors.

    For example:

    #*/3 * * * * sudo -i -u plixer /home/plixer/scrutinizer/bin/scrut_util --autoreplicate --verbose 2>&1 /home/plixer/scrutinizer/files/logs/autoreplicate.log
    

    This will run scrut_util --autoreplicate daily at 3 am, with logs saved to /home/plixer/scrutinizer/files/logs/autoreplicate.log

Collector limits

The configuration file will contain an entry defining the exporter and flow rate capacities for each remote collector in the cluster in the following format:

"COLLECTOR_ADDRESS" : {
   "exporters" : MAX_EXPORTER_COUNT,
       "flow_rate" : MAX_FLOW_RATE
}

These values are used by Plixer Scrutinizer to determine how exporters are assigned and can be edited as needed. Once auto-replication has been started, an exporter will only be reassigned if its current collector exceeds its configured exporter or flow rate capacity.

If additional collectors are deployed to the cluster at a later time, they should also be added to the configuration file.

Additional auto-replication settings

The following global auto-replication settings can also be edited in the configuration file:

  • replicator_host: Full address of the Plixer Replicator instance (must be formatted as https://REPLICATOR_IP)

  • replicator_pass: Password set for the replicator user account

  • replicator_seed_profile: Auto-replication seed profile name

  • replicator_receive_port: Listening/in port

  • replicator_send_port: Sending/out port

Because the values for these settings in the configuration file take precedence over those entered via the Plixer Scrutinizer web interface, the configuration file can be used to update auto-replication parameters at any time.

Password encryption

For added security, the plain text password in the configuration file can be replaced with its AES256-encrypted value.

To generate a password’s encrypted value, run:

scrut_util --autoreplicate --encrypt YOUR_PASSWORD

The output can then be assigned to replicator_pass in autoreplicate.conf.

Using multiple configurations

In certain scenarios, it may be necessary to use multiple auto-replicate configurations in the same environment.

These scenarios include:

  • Deploying multiple Plixer Replicator instances in the same Plixer Scrutinizer cluster

  • Setting up different listening/in and sending/out combinations for specific exporters

  • Creating collector groups for auto-replication

Sample multi-config setup

The following instructions outline the steps for setting up the directories and files for two autoreplicate.conf files:

  1. Create and configure a seed profile for each auto-replicate configuration on Plixer Replicator (e.g., Seed_Profile_1 and Seed_Profile_2).

  2. SSH to the primary Plixer Scrutinizer server/reporter as the plixer user, and then create a replicator_pools directory:

    cd /home/plixer/scrutinizer/
    mkdir replicator_pools
    
  3. Under replicator_pools, create a subdirectoy for each auto-replication configuration:

    mkdir replicator_pools/config_1
    mkdir replicator_pools/config_2
    
  4. Copy /home/plixer/scrutinizer/bin/scrut_util to each configuration subdirectory, and then rename it to replicator_util:

    cp /home/plixer/scrutinizer/bin/scrut_util /home/plixer/scrutinizer/replicator_pools/config_1/replicator_util
    cp /home/plixer/scrutinizer/bin/scrut_util /home/plixer/scrutinizer/replicator_pools/config_2/replicator_util
    
  5. Create the autoreplicate.conf file in each directory:

    touch replicator_pools/config_1/autoreplicate.conf
    touch replicator_pools/config_2/autoreplicate.conf
    
  6. Use the following template to configure auto-replication in each autoreplicate.conf:

    "collector_capacities" : {
       "COLLECTOR_1_ADDRESS" : {
              "exporters" : MAX_EXPORTER_COUNT,
                  "flow_rate" : MAX_FLOW_RATE
           },
       "COLLECTOR_2_ADDRESS" : {
              "exporters" : MAX_EXPORTER_COUNT,
                  "flow_rate" : MAX_FLOW_RATE
           }
    },
    "replicator_enable" : 1,
    "exporter_timeout" : 1800,
    "per_port_profile_name" : 1,
    "replicator_host" : REPLICATOR_ADDRESS,
    "replicator_pass" : REPLICATOR_PASSWORD,
    "replicator_receive_port" : LISTENING_PORT,
    "replicator_send_port" : SENDING_PORT,
    "replicator_seed_profile" : SEED_PROFILE_NAME
    

    Each file must be edited to reference the corresponding seed profile (e.g., Seed_Profile_1 or Seed_Profile_2) and the collectors to which exporters in that profile can be assigned. Additional parameters should also be defined for the configuration, if necessary.

  7. Run replicator_util --autoreplicate for each configuration file.

    replicator_pools/config_1/replicator_util --autoreplicate --verbose
    replicator_pools/config_2/replicator_util --autoreplicate --verbose
    
  8. [Optional] Create a cronjob for each auto-replication configuration to reset exporter-to-collector assignments at regular intervals:

    #*/3 * * * * sudo -i -u plixer /home/plixer/scrutinizer/files/replicator_pools/config_1/replicator_util --autoreplicate --verbose 2>&1 /home/plixer/scrutinizer/files/logs/autoreplicate.log
    #*/3 * * * * sudo -i -u plixer /home/plixer/scrutinizer/files/replicator_pools/config_2/replicator_util --autoreplicate --verbose 2>&1 /home/plixer/scrutinizer/files/logs/autoreplicate.log
    

Auto-replication will start after autoreplicate is run for each configuration file.

Note

  • To further organize auto-replication configurations, the directory structure can be expanded as needed, as long as the directories containing the autoreplicate.conf files are created under a directory called replicator_pools (e.g., /home/plixer/scrutinizer/autoreplicate/data_center_A/collector_group_X/replicator_pools/configuration_1).

  • Any time a seed profile or configuration file is modified, replicator_util --autoreplicate must be run in the corresponding directory to update Plixer Scrutinizer’s auto-replication configurations.

  • When setting up collector groups for auto-replication, using a unique listening/in port for exporters for each group is highly recommended.