One Master Node removes and adds cluster nodes on regular base

Hello,

The problem was the same as here:

It was solved by modifying the sysctl parameters:

 # Reduce keep alive values to increase frequency of keep alive packets sent across network in order to prevent ElasticSearch nodes losing connection between each other
net.ipv4.tcp_keepalive_time = 600
net.ipv4.tcp_keepalive_intvl = 60
net.ipv4.tcp_keepalive_probes = 20

Cheers!