Article title: Multi-Nic server load balancer in Ubuntu. Linux is a technology channel of the IT lab in China. Includes basic categories such as desktop applications, Linux system management, kernel research, embedded systems, and open source.
In fact, I cannot use such a powerful configuration in my own house. However, since the motherboard comes with two r8168 NICs, it is idle and I just need to configure it.
Configuring complex multi-Nic server load balancer in Windows is very simple in Linux.
The first step is to install ifenslave, which is a command under Ubuntu:
Sudo apt-get install ifenslave
Then modify the/etc/modprobe. d/arch/file. if it is a 32-bit system, it is i386. if it is a 64-bit Intel system, it is x86_64.
Add the following content:
Alias bond0 bonding
Options bond0 mode = balance-alb miimon = 100 max_bonds = 2
Finally, modify/etc/network/interfaces, comment out the original eth0 and eth1 configurations, and add the following content:
Auto bond0
Iface bond0 inet static
Address 192.168.1.3
Netmask 255.255.255.0
Gateway 192.168.1.1
Up/sbin/ifenslave bond0 eth0 eth1
Down/sbin/ifenslave-d bond0 eht0 eth1
OK. restart to enable the Nic server load balancer function. That's easy.