单网卡设置双IP(ubuntu,debian)

# This file describes the network interfaces availableon your system
# and how to activate them. For more information, see interfaces(5).
#/etc/network/interfaces

# The loopback network interface
auto lo
iface lo inet loopback

auto eth0
iface eth0 inet static
address 192.168.1.116
netmask 255.255.255.0
gateway 192.168.1.2

auto eth0:1
iface eth0:1 inet static
address 192.168.1.135
netmask 255.255.255.0
gateway 192.168.1.2

你可能感兴趣的:(单网卡设置双IP(ubuntu,debian))