Configuring load balancing for Log Receiver (LR)
You must enable the load balancer if multiple instances of LR are deployed. Deploy each instance of LR on a different node and ensure that the processing of logs is properly coordinated across all nodes.
Enabling Log Receiver (LR) load balancing
You must enable LR load balancing for a new installation or upgrade from the previous version of Unravel to the new version.
Enable the NGINX for load balancing multiple instances of the log receiver.
/
<unravel_installation_directory>
/unravel/manager service enable nginx --permanentMake Unravel daemons reachable over the network.
By default, most Unravel daemons are set up to be accessible only within the local network. Configure the daemons to enable communication between a log receiver on a second server and the daemons to be reachable from the wider network.
/
<unravel_installation_directory>
/unravel/manager config multinode public-listen enableAdd the additional LR node definition in the
unravel.yaml
file on the main server./
<unravel_installation_directory>
/unravel/manager config multinode add<hostkey>
<label>
<hostname>
--role log_receiverWhere:
is an internal Unravel reference. For example<hostkey>
lr-2
is the display name to identify the node. For example,<label>
ACME's second log receiver
is the hostname that runs the log receiver, which is used for generating the configuration.<hostname>
If the internal and external hostnames differ, add an optional
--host-alias
parameter to look up the configuration.<hostname>
Apply the configuration.
<Unravel installation directory>
/unravel/manager config applyStart Unravel.
<Unravel installation directory>
/unravel/manager startUnravel starts, and the load balancer sends traffic to the log receiver on the main Unravel server.
Installing Unravel using LR configuration
After you set up the LR configuration on the main node, do the following:
Copy the
unravel.yaml
file from the main node to the new server.For example:
/home/unravel
Install Unravel on the LR server. Use
unravel.yaml
as a parameter.<Unravel installation directory>
/unravel/versions/<Unravel version>
/setup --config /home/unravel/unravel.yamlSet Unravel license.
<Unravel installation directory>
/unravel/manager config license set<path of a license file>
Example:
/opt/unravel/manager config license set /tmp/license.txt
For more information, see Setting Unravel license.
Start Unravel on the LR server.
<Unravel installation directory>
/unravel/manager startAfter the load balancer detects that the LR is available, the load balancer starts sending traffic to the log receiver.
Disabling Log Receiver (LR) load balancing
Prerequisite
You must first uninstall Unravel from the LR server.
Perform the following steps on the LR server, assuming the LR server location is /opt/unravel
:
Stop Unravel.
/opt/unravel/manager stop
Uninstall Unravel.
/opt/unravel/manager uninstall
Perform the following steps on the main server:
Stop Unravel.
<unravel_installation_directory>
/unravel/manager stopDisable NGINX.
<unravel_installation_directory>
/unravel/manager service disable nginx --permanentRemove the second node configuration.
<unravel_installation_directory>
/unravel/manager config multinode remove <host-key>Where
is an internal Unravel reference used when adding the node. For example<host-key>
lr-2
Make Unravel daemons reachable within the local network.
<unravel_installation_directory>
/unravel/manager config multinode public-listen disableApply the configuration.
<unravel_installation_directory>
/unravel/manager config applyStart Unravel using one LR.
<unravel_installation_directory>
/unravel/manager start