1. Configure vip on lo
ip addr add 192.168.50.246/32 dev lo label lo:0
2. Suppress arp
echo 1 > /proc/sys/net/ipv4/conf/lo/arp_ignore
echo 1 > /proc/sys/net/ipv4/conf/all/arp_ignore
echo 2 > ; /proc/sys/net/ipv4/conf/lo/arp_announce
echo 2 > /proc/sys/net/ipv4/conf/all/arp_announce
arp_ignore:
0 (default value): Respond to ARP query requests for any local IP address on any network interface
1: Only respond to ARP query requests whose target IP address is the local address of the visiting network interface
arp_announce:
2: Use the most appropriate local address for the query target. In this mode, the source address of this IP packet will be ignored and try to select a local address that can communicate with this address. The first is to select All network interfaces in the subnet that are in the outbound access subnet contain the local address of the destination IP address. If no suitable address is found, the current sending network interface or other network interfaces that are likely to receive the ARP response will be selected to send, restricting the use of local VIP addresses as the preferred network interface
The above is the detailed content of How to configure the backend RS in lvs-dr mode. For more information, please follow other related articles on the PHP Chinese website!