Product SiteDocumentation Site

8.12. Changing Load Balancing for FreeIPA Servers and Replicas

As Section 1.3.1, “About FreeIPA Servers and Replicas” touches on, FreeIPA servers and replicas in the domain automatically share the load among instances to maintain performance. The load balancing is defined first by the priority set for the server or replica in its SRV entry, and then by the weight of that instance for servers/replicas with the same priority. Clients contact servers/replicas with the highest priority and then work their way down.
Load balancing is done automatically by servers, replicas, and clients. The configuration used for load balancing can be altered by changing the priority and the weight given to a server or replica.
(All replicas are initially created with the same priority.)
For example, this gives server1 a higher priority than server 2, meaning it will be contacted first:
$ ipa dnsrecord-add server.example.com _ldap._tcp --srv-rec="0 100 389 server1.example.com" 

$ ipa dnsrecord-add server.example.com _ldap._tcp --srv-rec="1 100 389 server2.example.com"
More information about SRV records is in RFC 2782.