L3/L4 Load Balancing with the Data Fabric Data Access Gateway
You can use haproxy for L3/L4 load balancing of clients that use the
Data Fabric Data Access Gateway. This topic describes
how to install, configure, and run haproxy, and how to set your client
connection string to connect to the load balancing service.
Prerequisites
Procedure
-
Install the
haproxyservice on the server you have identified:sudo yum install haproxysudo add-apt-repository ppa:vbernat/haproxy-1.7 sudo apt update sudo apt install haproxysudo zypper install haproxy -
Configure the
haproxyservice by setting the following parameters in the configuration file at/etc/haproxy/haproxy.cfg: -
Restart the
haproxyservice:sudo service haproxy restart
What to do next
Setting Your Client Connection String
Assume you have the following haproxy configuration settings and you
have installed haproxy on node1.cluster.com:
frontend connection_input
mode tcp
bind *:8553
default_backend maprdb_servers
backend maprdb_servers
mode tcp
server srv01 node1.cluster.com:5678
server srv02 node2.cluster.com:5678
You can use the following client connection string with this sample configuration:
node1.cluster.com:8553?auth=basic;user=mapr;password=mapr;ssl=true;sslCA=/opt/mapr/conf/ssl_truststore.pem;sslTargetNameOverride=node1.cluster.com
node1.cluster.com:8553?auth=basic;user=mapr;password=mapr;ssl=false