keepalived

The understanding of keepalived is:
in a local area network, a cluster is composed of several servers. Among them, one main server is elected, and the rest are backup servers. The main server will periodically broadcast an arp packet, the content of which is a virtual ip and its mac address. All hosts that have received the packet will update their ip ----- mac address mapping table. In this way, when the gateway receives this packet, it will send the ip request from the outside world to the main server, and the alternate server can know the survivors of the main server through this arp packet, so it does nothing. Suddenly, one day disaster struck, and the main server went down (hit by the cat stars). At this time, because the standby machine cannot receive the arp package from the main server, the standby machines are ready to compete to become the main server (small three upgrade). When a standby machine succeeds in the election, it will perform the responsibility of the host, and regularly broadcast an arp packet, the content of which is a virtual ip and its mac address (it has been converted by itself). When the gateway receives the arp packet, it updates its own ip mac address mapping table. The gateway can then forward requests from the outside world to the new host.

Guess you like

Origin http://10.200.1.11:23101/article/api/json?id=326615118&siteId=291194637