User Tools

Site Tools


tech:network:administrative-distance:administrative-distance

Administrative Distance

R1

int gig0/1
ip addr 172.16.1.1 255.255.255.0
no shut
int gig0/2
ip addr 172.16.2.1 255.255.255.0
no shut
int gig0/3
ip addr 172.16.3.1 255.255.255.0
no shut

R2

int gig0/1
ip addr 172.16.2.254 255.255.255.0
no shut
int gig0/2
ip addr 172.16.4.2 255.255.255.0
no shut

R3

int gig0/1
ip addr 172.16.3.254 255.255.255.0
no shut
int gig0/2
ip addr 172.16.4.3 255.255.255.0
no shut
cisco@server-2:~$ ip ro
default via 10.255.0.1 dev eth0 
10.0.0.0/29 dev eth1  proto kernel  scope link  src 10.0.0.2 
10.0.0.0/16 via 10.0.0.3 dev eth1 
10.0.0.0/16 via 10.0.0.1 dev eth1 
10.255.0.0/16 dev eth0  proto kernel  scope link  src 10.255.0.37 
169.254.169.254 via 10.255.0.1 dev eth0 
172.16.4.0/25 dev eth1  proto kernel  scope link  src 172.16.4.5 
192.168.0.0/29 via 10.0.0.3 dev eth1 
192.168.0.0/29 via 10.0.0.1 dev eth1 
cisco@server-2:~$ w
 23:44:47 up 12:32,  1 user,  load average: 0.00, 0.00, 0.00
USER     TTY      FROM             LOGIN@   IDLE   JCPU   PCPU WHAT
cisco    ttyS0                     23:20    7.00s  0.27s  0.00s w
cisco@server-2:~$ ip route del 0.0.0.0
RTNETLINK answers: Operation not permitted
cisco@server-2:~$ sudo ip route del 0.0.0.0
[sudo] password for cisco: 
RTNETLINK answers: No such process
cisco@server-2:~$ sudo ip route del 0.0.0.0/0
cisco@server-2:~$ ip ro
10.0.0.0/29 dev eth1  proto kernel  scope link  src 10.0.0.2 
10.0.0.0/16 via 10.0.0.3 dev eth1 
10.0.0.0/16 via 10.0.0.1 dev eth1 
10.255.0.0/16 dev eth0  proto kernel  scope link  src 10.255.0.37 
169.254.169.254 via 10.255.0.1 dev eth0 
172.16.4.0/25 dev eth1  proto kernel  scope link  src 172.16.4.5 
192.168.0.0/29 via 10.0.0.3 dev eth1 
192.168.0.0/29 via 10.0.0.1 dev eth1 
cisco@server-2:~$ 
cisco@server-2:~$ sudo ip route add 0.0.0.0/0 via 172.16.4.2
cisco@server-2:~$ ip ro
default via 172.16.4.2 dev eth1 
10.0.0.0/29 dev eth1  proto kernel  scope link  src 10.0.0.2 
10.0.0.0/16 via 10.0.0.3 dev eth1 
10.0.0.0/16 via 10.0.0.1 dev eth1 
10.255.0.0/16 dev eth0  proto kernel  scope link  src 10.255.0.37 
169.254.169.254 via 10.255.0.1 dev eth0 
172.16.4.0/25 dev eth1  proto kernel  scope link  src 172.16.4.5 
192.168.0.0/29 via 10.0.0.3 dev eth1 
192.168.0.0/29 via 10.0.0.1 dev eth1 
cisco@server-2:~$ 



cisco@server-1:~$ sudo ip route del 0.0.0.0/0
[sudo] password for cisco: 
cisco@server-1:~$ sudo ip route add 0.0.0.0/0 via 172.16.1.1
cisco@server-1:~$ ip ro
default via 172.16.1.1 dev eth1 
10.0.0.0/16 via 10.0.0.9 dev eth1 
10.0.0.8/30 dev eth1  proto kernel  scope link  src 10.0.0.10 
10.255.0.0/16 dev eth0  proto kernel  scope link  src 10.255.0.36 
169.254.169.254 via 10.255.0.1 dev eth0 
172.16.1.0/24 dev eth1  proto kernel  scope link  src 172.16.1.5 
192.168.0.0/29 via 10.0.0.9 dev eth1 
cisco@server-1:~$ 

References

tech/network/administrative-distance/administrative-distance.txt · Last modified: 2018/03/02 09:15 by wnoguchi