C:\>ping 192.4.23.11
Pinging 192.4.23.11 with 32 bytes of data:
Reply from 192.4.23.11: bytes=32 time=13ms TTL=123
Reply from 192.4.23.11: bytes=32 time=10ms TTL=123
Reply from 192.4.23.11: bytes=32 time=12ms TTL=123
Reply from 192.4.23.11: bytes=32 time=29ms TTL=123
Ping statistics for 192.4.23.11:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 10ms, Maximum = 29ms, Average = 16ms
R1(config)#int s0/0/0
R1(config-if)#ip address 3.3.3.1 255.255.255.252
R1(config-if)#no shutdown
R1#show ip int brief
Interface IP-Address OK? Method Status Protocol
GigabitEthernet0/0 1.1.1.1 YES manual up up
GigabitEthernet0/1 unassigned YES unset administratively down down
Serial0/0/0 3.3.3.1 YES manual up up
Serial0/0/1 unassigned YES unset administratively down down
Vlan1 unassigned YES unset administratively down down
R2
R2(config)#int s0/0/0
R2(config-if)#ip address 3.3.3.2 255.255.255.252
R2(config-if)#no shutdown
R2(config-if)#int s0/0/1
R2(config-if)#ip address 3.3.3.5 255.255.255.252
R2(config-if)#no shutdown
R2(config-if)#do show ip int brief
Interface IP-Address OK? Method Status Protocol
GigabitEthernet0/0 unassigned YES unset administratively down down
GigabitEthernet0/1 unassigned YES unset administratively down down
Serial0/0/0 3.3.3.2 YES manual up up
Serial0/0/1 3.3.3.5 YES manual up up
Vlan1 unassigned YES unset administratively down down
R3
R3(config)#int s0/0/0
R3(config-if)#ip address 3.3.3.6 255.255.255.252
R3(config-if)#no shutdown
R3(config-if)#do show ip int brief
Interface IP-Address OK? Method Status Protocol
GigabitEthernet0/0 2.2.2.1 YES manual up up
GigabitEthernet0/1 unassigned YES unset administratively down down
Serial0/0/0 3.3.3.6 YES manual up up
Serial0/0/1 unassigned YES unset administratively down down
Vlan1 unassigned YES unset administratively down down
라우팅 설정 전 PC1 > PC2 테스트
핑이 되지 않는다.
C:\>ping 2.2.2.11
Pinging 2.2.2.11 with 32 bytes of data:
Reply from 1.1.1.1: Destination host unreachable.
Reply from 1.1.1.1: Destination host unreachable.
Reply from 1.1.1.1: Destination host unreachable.
Reply from 1.1.1.1: Destination host unreachable.
Ping statistics for 2.2.2.11:
Packets: Sent = 4, Received = 0, Lost = 4 (100% loss),
R1#show ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area
* - candidate default, U - per-user static route, o - ODR
P - periodic downloaded static route
Gateway of last resort is not set
1.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C 1.1.1.0/24 is directly connected, GigabitEthernet0/0
L 1.1.1.1/32 is directly connected, GigabitEthernet0/0
R 2.0.0.0/8 [120/2] via 3.3.3.2, 00:00:12, Serial0/0/0
3.0.0.0/8 is variably subnetted, 3 subnets, 2 masks
C 3.3.3.0/30 is directly connected, Serial0/0/0
L 3.3.3.1/32 is directly connected, Serial0/0/0
R 3.3.3.4/30 [120/1] via 3.3.3.2, 00:00:12, Serial0/0/0
R2
R2#show ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area
* - candidate default, U - per-user static route, o - ODR
P - periodic downloaded static route
Gateway of last resort is not set
R 1.0.0.0/8 [120/1] via 3.3.3.1, 00:00:20, Serial0/0/0
R 2.0.0.0/8 [120/1] via 3.3.3.6, 00:00:23, Serial0/0/1
3.0.0.0/8 is variably subnetted, 4 subnets, 2 masks
C 3.3.3.0/30 is directly connected, Serial0/0/0
L 3.3.3.2/32 is directly connected, Serial0/0/0
C 3.3.3.4/30 is directly connected, Serial0/0/1
L 3.3.3.5/32 is directly connected, Serial0/0/1
R3
R3#show ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area
* - candidate default, U - per-user static route, o - ODR
P - periodic downloaded static route
Gateway of last resort is not set
R 1.0.0.0/8 [120/2] via 3.3.3.5, 00:00:05, Serial0/0/0
2.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C 2.2.2.0/24 is directly connected, GigabitEthernet0/0
L 2.2.2.1/32 is directly connected, GigabitEthernet0/0
3.0.0.0/8 is variably subnetted, 3 subnets, 2 masks
R 3.3.3.0/30 [120/1] via 3.3.3.5, 00:00:05, Serial0/0/0
C 3.3.3.4/30 is directly connected, Serial0/0/0
L 3.3.3.6/32 is directly connected, Serial0/0/0
PC1 테스트
C:\>ping 2.2.2.11
Pinging 2.2.2.11 with 32 bytes of data:
Request timed out.
Reply from 2.2.2.11: bytes=32 time=7ms TTL=125
Reply from 2.2.2.11: bytes=32 time=9ms TTL=125
Reply from 2.2.2.11: bytes=32 time=9ms TTL=125
Ping statistics for 2.2.2.11:
Packets: Sent = 4, Received = 3, Lost = 1 (25% loss),
Approximate round trip times in milli-seconds:
Minimum = 7ms, Maximum = 9ms, Average = 8ms
C:\>ping 3.3.3.5
Pinging 3.3.3.5 with 32 bytes of data:
Reply from 3.3.3.5: bytes=32 time=6ms TTL=254
Reply from 3.3.3.5: bytes=32 time=6ms TTL=254
Reply from 3.3.3.5: bytes=32 time=6ms TTL=254
Reply from 3.3.3.5: bytes=32 time=4ms TTL=254
Ping statistics for 3.3.3.5:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 4ms, Maximum = 6ms, Average = 5ms
PC2 테스트
C:\>ping 1.1.1.11
Pinging 1.1.1.11 with 32 bytes of data:
Reply from 1.1.1.11: bytes=32 time=10ms TTL=125
Reply from 1.1.1.11: bytes=32 time=8ms TTL=125
Reply from 1.1.1.11: bytes=32 time=8ms TTL=125
Reply from 1.1.1.11: bytes=32 time=9ms TTL=125
Ping statistics for 1.1.1.11:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 8ms, Maximum = 10ms, Average = 8ms
C:\>ping 3.3.3.1
Pinging 3.3.3.1 with 32 bytes of data:
Reply from 3.3.3.1: bytes=32 time=8ms TTL=253
Reply from 3.3.3.1: bytes=32 time=7ms TTL=253
Reply from 3.3.3.1: bytes=32 time=6ms TTL=253
Reply from 3.3.3.1: bytes=32 time=8ms TTL=253
Ping statistics for 3.3.3.1:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 6ms, Maximum = 8ms, Average = 7ms
2. default route 설정을 이용
1번 파일에서 설정한다.
loopback 인터페이스를 활성화
R2(config)#int loopback0
R2(config-if)#
%LINK-5-CHANGED: Interface Loopback0, changed state to up
%LINEPROTO-5-UPDOWN: Line protocol on Interface Loopback0, changed state to up
R2(config-if)#ip add 10.10.10.1 255.255.255.0
R2(config-if)#do show ip int brief
Interface IP-Address OK? Method Status Protocol
GigabitEthernet0/0 unassigned YES unset administratively down down
GigabitEthernet0/1 unassigned YES unset administratively down down
Serial0/0/0 3.3.3.2 YES manual up up
Serial0/0/1 3.3.3.5 YES manual up up
Loopback0 10.10.10.1 YES manual up up
Vlan1 unassigned YES unset administratively down down
default route 인터페이스를 지정하고 이를 rip이 광고하도록 설정
R2(config-if)#ip route 0.0.0.0 0.0.0.0 loopback0
%Default route without gateway, if not a point-to-point interface, may impact performance
R2(config)#router rip
R2(config-router)#default-information originate
R2(config-router)#do show ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area
* - candidate default, U - per-user static route, o - ODR
P - periodic downloaded static route
Gateway of last resort is 0.0.0.0 to network 0.0.0.0
R 1.0.0.0/8 [120/1] via 3.3.3.1, 00:00:18, Serial0/0/0
R 2.0.0.0/8 [120/1] via 3.3.3.6, 00:00:20, Serial0/0/1
3.0.0.0/8 is variably subnetted, 4 subnets, 2 masks
C 3.3.3.0/30 is directly connected, Serial0/0/0
L 3.3.3.2/32 is directly connected, Serial0/0/0
C 3.3.3.4/30 is directly connected, Serial0/0/1
L 3.3.3.5/32 is directly connected, Serial0/0/1
10.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C 10.10.10.0/24 is directly connected, Loopback0
L 10.10.10.1/32 is directly connected, Loopback0
S* 0.0.0.0/0 is directly connected, Loopback0
default route 정보가 갱신되었는지 확인
R1
R1#show ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area
* - candidate default, U - per-user static route, o - ODR
P - periodic downloaded static route
Gateway of last resort is 3.3.3.2 to network 0.0.0.0
1.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C 1.1.1.0/24 is directly connected, GigabitEthernet0/0
L 1.1.1.1/32 is directly connected, GigabitEthernet0/0
R 2.0.0.0/8 [120/2] via 3.3.3.2, 00:00:20, Serial0/0/0
3.0.0.0/8 is variably subnetted, 3 subnets, 2 masks
C 3.3.3.0/30 is directly connected, Serial0/0/0
L 3.3.3.1/32 is directly connected, Serial0/0/0
R 3.3.3.4/30 [120/1] via 3.3.3.2, 00:00:20, Serial0/0/0
R* 0.0.0.0/0 [120/1] via 3.3.3.2, 00:00:20, Serial0/0/0
R2
R2#show ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area
* - candidate default, U - per-user static route, o - ODR
P - periodic downloaded static route
Gateway of last resort is 0.0.0.0 to network 0.0.0.0
R 1.0.0.0/8 [120/1] via 3.3.3.1, 00:00:22, Serial0/0/0
R 2.0.0.0/8 [120/1] via 3.3.3.6, 00:00:18, Serial0/0/1
3.0.0.0/8 is variably subnetted, 4 subnets, 2 masks
C 3.3.3.0/30 is directly connected, Serial0/0/0
L 3.3.3.2/32 is directly connected, Serial0/0/0
C 3.3.3.4/30 is directly connected, Serial0/0/1
L 3.3.3.5/32 is directly connected, Serial0/0/1
10.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C 10.10.10.0/24 is directly connected, Loopback0
L 10.10.10.1/32 is directly connected, Loopback0
S* 0.0.0.0/0 is directly connected, Loopback0
R3
R3#show ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area
* - candidate default, U - per-user static route, o - ODR
P - periodic downloaded static route
Gateway of last resort is 3.3.3.5 to network 0.0.0.0
R 1.0.0.0/8 [120/2] via 3.3.3.5, 00:00:11, Serial0/0/0
2.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C 2.2.2.0/24 is directly connected, GigabitEthernet0/0
L 2.2.2.1/32 is directly connected, GigabitEthernet0/0
3.0.0.0/8 is variably subnetted, 3 subnets, 2 masks
R 3.3.3.0/30 [120/1] via 3.3.3.5, 00:00:11, Serial0/0/0
C 3.3.3.4/30 is directly connected, Serial0/0/0
L 3.3.3.6/32 is directly connected, Serial0/0/0
R* 0.0.0.0/0 [120/1] via 3.3.3.5, 00:00:11, Serial0/0/0
PC1 테스트
C:\>ping 2.2.2.11
Pinging 2.2.2.11 with 32 bytes of data:
Request timed out.
Reply from 2.2.2.11: bytes=32 time=6ms TTL=125
Reply from 2.2.2.11: bytes=32 time=6ms TTL=125
Reply from 2.2.2.11: bytes=32 time=7ms TTL=125
Ping statistics for 2.2.2.11:
Packets: Sent = 4, Received = 3, Lost = 1 (25% loss),
Approximate round trip times in milli-seconds:
Minimum = 6ms, Maximum = 7ms, Average = 6ms
C:\>ping 3.3.3.5
Pinging 3.3.3.5 with 32 bytes of data:
Reply from 3.3.3.5: bytes=32 time=10ms TTL=254
Reply from 3.3.3.5: bytes=32 time=5ms TTL=254
Reply from 3.3.3.5: bytes=32 time=5ms TTL=254
Reply from 3.3.3.5: bytes=32 time=7ms TTL=254
Ping statistics for 3.3.3.5:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 5ms, Maximum = 10ms, Average = 6ms
PC2 테스트
C:\>ping 1.1.1.11
Pinging 1.1.1.11 with 32 bytes of data:
Reply from 1.1.1.11: bytes=32 time=9ms TTL=125
Reply from 1.1.1.11: bytes=32 time=8ms TTL=125
Reply from 1.1.1.11: bytes=32 time=7ms TTL=125
Reply from 1.1.1.11: bytes=32 time=9ms TTL=125
Ping statistics for 1.1.1.11:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 7ms, Maximum = 9ms, Average = 8ms
C:\>ping 3.3.3.1
Pinging 3.3.3.1 with 32 bytes of data:
Reply from 3.3.3.1: bytes=32 time=6ms TTL=253
Reply from 3.3.3.1: bytes=32 time=9ms TTL=253
Reply from 3.3.3.1: bytes=32 time=13ms TTL=253
Reply from 3.3.3.1: bytes=32 time=6ms TTL=253
Ping statistics for 3.3.3.1:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 6ms, Maximum = 13ms, Average = 8ms
◾ Router에 RIP 설정 • 라우터가 알고있는 네트워크 정보를 광고하도록 지정한다. • Classful 알고리즘이므로 넷마스크를 입력하지 않는다. • 라우터에 연결된 모든 네트워크 정보를 모두 입력한다.
• 중간에 거쳐가는 라우터가 적은 쪽으로 이동
◾ 명령어 • router [rip | ospf | eigrp | bgp] : 각 프로토콜 설정모드로 진입 • network [IP] : 광고할 네트워크 주소를 지정 - 라우터에 연결된 모든 네트워크 주소를 입력한다. - rip은 넷마스크를 입력하지 않는다.
◾ 라우팅 정보 확인 • show ip route [rip]
◾ 불필요한 업데이트 금지 • R1이나 R2, R3의 GigbitEthernet 영역은 라우팅 정보를 수신할 라우터가 없는 곳이므로 해당 인터페이스로 라우팅 정보를 업데이트 할 필요가 없다. • passive‐interface [interface] : 해당 인터페이스로는 라우팅 정보를 업데이트하지 않는다.
R1(config-router)#passive-interface g0/0
RIP 실습
R1
R1(config-if)#do show ip int brief
Interface IP-Address OK? Method Status Protocol
GigabitEthernet0/0 1.4.1.1 YES manual up up
GigabitEthernet0/1 unassigned YES unset administratively down down
Serial0/0/0 1.4.11.1 YES manual down down
Serial0/0/1 1.4.13.2 YES manual down down
Vlan1 unassigned YES unset administratively down down
R2
R2(config-if)#do show ip int brief
Interface IP-Address OK? Method Status Protocol
GigabitEthernet0/0 1.4.2.1 YES manual up up
GigabitEthernet0/1 unassigned YES unset administratively down down
Serial0/0/0 1.4.11.2 YES manual up up
Serial0/0/1 1.4.12.1 YES manual down down
Vlan1 unassigned YES unset administratively down down
R3
R3#show ip int brief
Interface IP-Address OK? Method Status Protocol
GigabitEthernet0/0 1.4.3.1 YES manual up up
GigabitEthernet0/1 unassigned YES unset administratively down down
Serial0/0/0 1.4.13.1 YES manual up up
Serial0/0/1 1.4.12.2 YES manual up up
Vlan1 unassigned YES unset administratively down down
라우터 RIP 설정
R1, R2, R3 모두 설정한다.
R1(config)#router rip
R1(config-router)#network 1.4.1.0
R1(config-router)#network 1.4.11.0
R1(config-router)#network 1.4.13.0
R1(config-router)#passive-interface g0/0 < 불필요한 업데이트 금지
라우터 RIP 설정 확인
R1#show start
...
router rip
network 1.0.0.0
...
라우팅 정보 확인
R1#show ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area
* - candidate default, U - per-user static route, o - ODR
P - periodic downloaded static route
Gateway of last resort is not set
1.0.0.0/8 is variably subnetted, 9 subnets, 2 masks
C 1.4.1.0/24 is directly connected, GigabitEthernet0/0
L 1.4.1.1/32 is directly connected, GigabitEthernet0/0
R 1.4.2.0/24 [120/1] via 1.4.11.2, 00:00:27, Serial0/0/0
R 1.4.3.0/24 [120/1] via 1.4.13.1, 00:00:08, Serial0/0/1
C 1.4.11.0/24 is directly connected, Serial0/0/0
L 1.4.11.1/32 is directly connected, Serial0/0/0
R 1.4.12.0/24 [120/1] via 1.4.11.2, 00:00:27, Serial0/0/0
[120/1] via 1.4.13.1, 00:00:08, Serial0/0/1
C 1.4.13.0/24 is directly connected, Serial0/0/1
L 1.4.13.2/32 is directly connected, Serial0/0/1
PC에서 테스트
PC1
C:\>ping 1.4.2.11
Pinging 1.4.2.11 with 32 bytes of data:
Request timed out.
Reply from 1.4.2.11: bytes=32 time=5ms TTL=126
Reply from 1.4.2.11: bytes=32 time=6ms TTL=126
Reply from 1.4.2.11: bytes=32 time=5ms TTL=126
Ping statistics for 1.4.2.11:
Packets: Sent = 4, Received = 3, Lost = 1 (25% loss),
Approximate round trip times in milli-seconds:
Minimum = 5ms, Maximum = 6ms, Average = 5ms
C:\>ping 1.4.3.11
Pinging 1.4.3.11 with 32 bytes of data:
Reply from 1.4.3.11: bytes=32 time=8ms TTL=126
Reply from 1.4.3.11: bytes=32 time=6ms TTL=126
Reply from 1.4.3.11: bytes=32 time=7ms TTL=126
Reply from 1.4.3.11: bytes=32 time=6ms TTL=126
Ping statistics for 1.4.3.11:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 6ms, Maximum = 8ms, Average = 6ms
RIP - extra
◾ 변경 정보 전달(Route Poisoning, Poisoning Reverse) • 라우터에 변경(장애나 수정)이 발생하면 즉시 수정된 라우팅 정보를 전달한다. • 이때 접근 이 불가능한 16 hops를 전달한다. • R3의 G0/0을 다운시키고 전달되는 라우팅 정보를 확인한다.
R1#debug ip rip
RIP protocol debugging is on
R1#RIP: sending v1 update to 255.255.255.255 via Serial0/0/0 (1.4.11.1)
RIP: build update entries
network 1.4.1.0 metric 1
network 1.4.3.0 metric 2
network 1.4.13.0 metric 1
RIP: sending v1 update to 255.255.255.255 via Serial0/0/1 (1.4.13.2)
RIP: build update entries
network 1.4.1.0 metric 1
network 1.4.2.0 metric 2
network 1.4.11.0 metric 1
RIP: received v1 update from 1.4.13.1 on Serial0/0/1
1.4.2.0 in 2 hops
1.4.3.0 in 1 hops
1.4.12.0 in 1 hops
RIP: received v1 update from 1.4.11.2 on Serial0/0/0
1.4.2.0 in 1 hops
1.4.3.0 in 2 hops
1.4.12.0 in 1 hops
RIP: sending v1 update to 255.255.255.255 via Serial0/0/0 (1.4.11.1)
RIP: build update entries
network 1.4.1.0 metric 1
network 1.4.3.0 metric 2
network 1.4.13.0 metric 1
RIP: sending v1 update to 255.255.255.255 via Serial0/0/1 (1.4.13.2)
RIP: build update entries
network 1.4.1.0 metric 1
network 1.4.2.0 metric 2
network 1.4.11.0 metric 1
RIP: received v1 update from 1.4.13.1 on Serial0/0/1
1.4.2.0 in 2 hops
1.4.3.0 in 1 hops
1.4.12.0 in 1 hops
RIP: received v1 update from 1.4.11.2 on Serial0/0/0
1.4.2.0 in 1 hops
1.4.3.0 in 2 hops
1.4.12.0 in 1 hops
...
R1#no debug ip rip
RIP protocol debugging is off
RIP - extra : default route
◾ RIP을 이용한 default route 정보 전달 • 정적 라우팅 환경에서는 라우터에 직접 default route 정보를 설정했으나 RIP에서는 default route 정보를 RIP를 통해 전달 가능하다. • 명령 [ default‐information originate ] : RIP을 통해 default route 정보를 전달한다.
◾ Default router 설정 • default route 설정은 정적 라우팅 설정과 동일하다. • 외부 네트워크로 local loopback 인터페이스를 이용한다. (가짜 인터페이스를 생성) - loopback 인터페이스를 인터넷(ISP) 연결로 간주한다. (default route로 지정)
- no shutdown 으로 활성화를 할 필요가 없다. (가짜 인터페이스라서)
◾ loopback 인터페이스를 활성화 한다.
• 가상 인터페이스로 no shutdown 명령이 불필요하다. • 10.10.10.0/24는 RIP 라우팅에 등록하지 않는다.
R1(config)#int loopback0
R1(config-if)#
%LINK-5-CHANGED: Interface Loopback0, changed state to up
%LINEPROTO-5-UPDOWN: Line protocol on Interface Loopback0, changed state to up
R1(config-if)#ip address 10.10.10.1 255.255.255.0
R1(config-if)#do show ip int brief
Interface IP-Address OK? Method Status Protocol
GigabitEthernet0/0 1.4.1.1 YES manual up up
GigabitEthernet0/1 unassigned YES unset administratively down down
Serial0/0/0 1.4.11.1 YES manual up up
Serial0/0/1 1.4.13.2 YES manual up up
Loopback0 10.10.10.1 YES manual up up
Vlan1 unassigned YES unset administratively down down
◾ default route 인터페이스를 지정하고 이를 rip이 광고하도록 설정
R1(config)#ip route 0.0.0.0 0.0.0.0 loopback0
%Default route without gateway, if not a point-to-point interface, may impact performance
R1(config)#router rip
R1(config-router)#default-information originate
R1(config-router)#exit
R1(config)#do show ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area
* - candidate default, U - per-user static route, o - ODR
P - periodic downloaded static route
Gateway of last resort is 0.0.0.0 to network 0.0.0.0
1.0.0.0/8 is variably subnetted, 9 subnets, 2 masks
C 1.4.1.0/24 is directly connected, GigabitEthernet0/0
L 1.4.1.1/32 is directly connected, GigabitEthernet0/0
R 1.4.2.0/24 [120/1] via 1.4.11.2, 00:00:20, Serial0/0/0
R 1.4.3.0/24 [120/1] via 1.4.13.1, 00:00:24, Serial0/0/1
C 1.4.11.0/24 is directly connected, Serial0/0/0
L 1.4.11.1/32 is directly connected, Serial0/0/0
R 1.4.12.0/24 [120/1] via 1.4.13.1, 00:00:24, Serial0/0/1
[120/1] via 1.4.11.2, 00:00:20, Serial0/0/0
C 1.4.13.0/24 is directly connected, Serial0/0/1
L 1.4.13.2/32 is directly connected, Serial0/0/1
10.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C 10.10.10.0/24 is directly connected, Loopback0
L 10.10.10.1/32 is directly connected, Loopback0
S* 0.0.0.0/0 is directly connected, Loopback0
R2, R3에서도 default route 정보가 갱신되었는지 확인
R2#show ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, ia - IS-IS inter area
* - candidate default, U - per-user static route, o - ODR
P - periodic downloaded static route
Gateway of last resort is 1.4.11.1 to network 0.0.0.0
1.0.0.0/8 is variably subnetted, 9 subnets, 2 masks
R 1.4.1.0/24 [120/1] via 1.4.11.1, 00:00:08, Serial0/0/0
C 1.4.2.0/24 is directly connected, GigabitEthernet0/0
L 1.4.2.1/32 is directly connected, GigabitEthernet0/0
R 1.4.3.0/24 [120/1] via 1.4.12.2, 00:00:26, Serial0/0/1
C 1.4.11.0/24 is directly connected, Serial0/0/0
L 1.4.11.2/32 is directly connected, Serial0/0/0
C 1.4.12.0/24 is directly connected, Serial0/0/1
L 1.4.12.1/32 is directly connected, Serial0/0/1
R 1.4.13.0/24 [120/1] via 1.4.12.2, 00:00:26, Serial0/0/1
[120/1] via 1.4.11.1, 00:00:08, Serial0/0/0
R* 0.0.0.0/0 [120/1] via 1.4.11.1, 00:00:08, Serial0/0/0