1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
root@debian13:~# cat /etc/network/interfaces
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).
source /etc/network/interfaces.d/*
# The loopback network interface
auto lo
iface lo inet loopback
# The primary network interface
allow-hotplug eth0
iface eth0 inet dhcp
metric 99 # 优先级低越优先
allow-hotplug eth1
iface eth1 inet static
address 192.168.44.2
netmask 255.255.255.0
# gateway 192.168.44.1
metric 100
root@debian13:~#
|