Article Title: how to configure a large number of IP addresses in RedhatLinux. 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.
If you want to configure hundreds or even thousands of IP addresses in linux, it will be very cumbersome to configure them in the conventional way.
For redhat linux, you can use the following method:
File:/etc/sysconfig/network-scripts/ifcfg-eth0-range0
Content
DEVICE = eth0
ONBOOT = yes
BOOTPROTO = static
IPADDR_START = 10.0.0.111
IPADDR_END = 10.0.0.199
CLONENUM_START = 0
GATEWAY = 10.0.0.1
NETMASK = 00000000000
NO_ALIASROUTING = yes
File:/etc/sysconfig/network-scripts/ifcfg-eth0-range1
Content
DEVICE = eth0
ONBOOT = yes
BOOTPROTO = static
IPADDR_START = 10.0.0.200
IPADDR_END = 10.0.0.254
CLONENUM_START = 5
GATEWAY = 10.0.0.1
NETMASK = 00000000000
NO_ALIASROUTING = yes
Then the service network restart
10.0.111-254 is configured to eth0.