Ubuntu Pastebin

Paste from multi-nic routes at Tue, 29 Mar 2016 20:40:35 +0000

Download as text
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
auto lo
iface lo inet loopback
auto eth0
iface eth0 inet static
    address 192.168.1.10
    netmask 255.255.255.0
    network 192.168.1.0
    broadcast 192.168.1.254
    post-up route add default gw 192.168.1.1 metric 1
    pre-down route del default gw 192.168.1.1

auto eth1
iface eth1 inet static
    address 192.168.2.10
    netmask 255.255.255.0
    network 192.168.2.0
    broadcast 192.168.2.254
    post-up route add default gw 192.168.2.1 metric 2
    pre-down route del default gw 192.168.2.1

root:-$ /etc/network# route -n
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
192.168.2.0     0.0.0.0         255.255.255.0   U     0      0        0 eth1
192.168.1.0     0.0.0.0         255.255.255.0   U     0      0        0 eth0
169.254.0.0     0.0.0.0         255.255.0.0     U     1000   0        0 eth0
0.0.0.0         192.168.1.1     0.0.0.0         UG    1      0        0 eth0
0.0.0.0         192.168.2.1     0.0.0.0         UG    2      0        0 eth1
Download as text