@thehow Short answer - you can't do that. That's the nature of TCP communication and load-balancing. If you have a load-balancer you have one TCP connection from your client to the LB and another connection from LB to the server. Unless your application protocol can relay the information about the original connection source (like the X-Forwarded-For header in HTTP request), that information is simply lost. There is no mechanism on the TCP layer allowing you to pass that info. @thambisetty With production HA CM setup you should have a reliable mechanism pointing your peers to the primary CM instance. With DNS it's very questionable. Not only it's not very common to have a DNS server dynamically updating DNS records based on some health check but also caching on the client's side can cause stale entries. (or you set cache timeout to some ridiculously low value which will cause your clients to have to resolve DNS with each connection request).
... View more