How to Configure Virtual IP in cassandra.yaml file? If there is no VIP, then how client/user will connect to cluster with 4 nodes?
@szbhojan_49886 We do not recommend the use of a virtual IP or a hardware/software load-balancer for Cassandra because the clients/apps use the built-in load-balancing policy on the Cassandra drivers.
For example if you are using the Java driver, by default the driver uses a load-balancing policy that routes queries to the local data centre with a token-aware policy that prefers to route requests to replicas (nodes) that own the data being queried.
The driver knows about the nodes in the cluster because it connects to contact points (whitelist of node IP addresses) to establish a control connection at startup time. The driver uses the control connection to perform tasks that include querying the system tables to learn about the cluster topology. Using the control connection, the driver also listens for changes to the cluster automatically so it is aware of things like node additions, node outages, new data centres and decommissions in real time.
For this reason, it is not advisable to use external load balancers or DNS virtual IPs since it affects the ability of the drivers to operate in the optimum way.
8 People are following this question.