我有带两张网卡的 debian 8,eth0以及eth1.
eth0是 192.168.3.43 和eth1192.168.3.44。
两者都由 dhcp 配置:
auto eth0
iface eth0 inet dhcp
auto eth1
iface eth1 inet dhcp
Run Code Online (Sandbox Code Playgroud)
这是路由表:
Destination Gateway Genmask Flags Metric Ref Use Iface
0.0.0.0 192.168.3.1 0.0.0.0 UG 0 0 0 eth0
192.168.3.0 0.0.0.0 255.255.255.128 U 0 0 0 eth0
192.168.3.0 0.0.0.0 255.255.255.128 U 0 0 0 eth1
Run Code Online (Sandbox Code Playgroud)
问题是,如果我从 eth0 上拔下电缆,即使在同一 192.168.3.x 网段中的机器上也无法 ping eth1。
我会理解其中一个是否在不同的网段中,因为路由表显示默认网关位于 eth0 上,但当这发生在我的主机所在的同一网段时,我会理解。
我需要什么才能使两张卡彼此独立工作?