Installing Collector

DCXUser Creation

Procedure

  1. To create a DCXUser, run the following commands in the same order as mentioned:
    sudo useradd -m dcxuser
    sudo usermod -aG wheel dcxuser
    sudo bash -c 'echo "dcxuser ALL=(ALL) NOPASSWD: ALL" >> /etc/sudoers'
    sudo passwd dcxuser
  2. Log in as the newly created DCXUser.

Accessing the Executable ZIP file

Procedure

  1. Copy the collector.zip file and paste it in the /home/dcxuser/ location.
  2. Navigate to /home/dcxuser/ and execute the following command:
    sudo unzip collector.zip
  3. After unzipping collector.zip, execute the following commands:
    sudo chown -R dcxuser Collector
    sudo chgrp -R dcxuser Collector
    sudo chmod +x Collector/collector.sh
    sudo chmod +x Collector/KafkaStandalone/bin/*.sh
    sudo chmod 755 Collector/logs/

Creating Topics in Kafka

Procedure

  1. Navigate to the path /home/dcxuser/Collector/KafkaStandalone/bin
  2. Create a topic by executing the following command:
    execute ‘./kafka-topics.sh --create --topic <TOPIC> --bootstrap-server <IP>:9092 --partitions 1 --replication-factor 1

    replace <TOPIC> with an appropriate topic name. For example, SampleCustomFilename-TEST.

  3. Navigate to the /home/dcxuser/Collector/Collector location and open the file wscollectorConf.properties.
  4. Replace all instances of <TOPIC> with an appropriate topic name. For example, replace <TOPIC> with SampleCustomFilename-TEST.

Changes in Configuration

Procedure

  1. Navigate to /home/dcxuser/Collector/Collector.
  2. Open the wscollectorConf.properties file.
  3. Replace all instances of the <IP address> with the system IP address.
  4. Open the wscollector.properties file.
  5. Replace instances of <HOST> with the Transport Service host IP address.

Collector Scripts

Procedure

  1. Navigate to /home/dcxuser/Collector.
  2. To start the Collector Services, run the following command: ./collector.sh start
    Note: The services may require 30 seconds to start.
  3. Simultaneously, you can the service status using the command ./collector.sh status
    Zookeeper, Kafka, and Collector must all be in a running state.
  4. If any service does not start properly, stop the services and start it again. To stop the service, run the command ./collector.sh stop

Configuring Transport Service Machine

Procedure

In the DiscoverCaptureSocket.cfg file, within the Globals section, add the flag IsDataFromCollector as shown in the following example.
[Globals]
...
...
IsDataFromCollector=N
If the value of the flag is:
  • Y - Collector mode is applicable
  • N - DNCA mode is applicable

Configuring UIC

About this task

In UIC add the following lines of code within the reqHeaders.push section containing the dcxCookieValue:
reqHeaders.push (
    {
        name: "X-Discover-SaaS-TLTSID",
        value: dcxCookieValue
    },
    {
        name: "appKey",
        value: '3ab520ca96584d09b837baa1d37ff31e'
    }
);
Note: Add only the value that is bold.