04. 네트워크 - 동적라우팅 (+ 실습)
동적라우팅
범위
• IGP(Interior Gateway Protocol) : RIP(v1, v2), IGRP, OSPF
• EGP(Exterior Gateway Protocol) : EGP, BGP
라우팅 정보
• Distance Vector : RIP(v1, v2), IGRP
• Link State : OSPF
VLSM
• Classful : RIP v1, IGRP
• Classless : RIP v2, OSPF
RIP
◾ Router에 RIP 설정
• 라우터가 알고있는 네트워크 정보를 광고하도록 지정한다.
• Classful 알고리즘이므로 넷마스크를 입력하지 않는다.
• 라우터에 연결된 모든 네트워크 정보를 모두 입력한다.
• 중간에 거쳐가는 라우터가 적은 쪽으로 이동
◾ 명령어
• router [rip | ospf | eigrp | bgp]
: 각 프로토콜 설정모드로 진입
• network [IP]
: 광고할 네트워크 주소를 지정
- 라우터에 연결된 모든 네트워크 주소를 입력한다.
- rip은 넷마스크를 입력하지 않는다.
◾ 라우팅 정보 확인
• show ip route [rip]
◾ 불필요한 업데이트 금지
• R1이나 R2, R3의 GigbitEthernet 영역은 라우팅 정보를 수신할 라우터가 없는 곳이므로 해당 인터페이스로 라우팅 정보를 업데이트 할 필요가 없다.
• passive‐interface [interface]
: 해당 인터페이스로는 라우팅 정보를 업데이트하지 않는다
[R1]
R1# show ip int brief
Interface IP‐Address OK? Method Status Protocol
GigabitEthernet0/0 1.1.1.1 YES manual up up
Serial0/0/0 12.1.1.1 YES manual up up
Serial0/0/1 31.1.1.1 YES manual up up
라우터 RIP 설정
R1(config)# router rip
R1(config‐router)# network 1.1.1.0
R1(config‐router)# network 12.1.1.0
R1(config‐router)# network 31.1.1.0
[R2]
R2# show ip int brief
Interface IP‐Address OK? Method Status Protocol
GigabitEthernet0/0 2.2.2.1 YES manual up up
Serial0/0/0 23.1.1.2 YES manual up up
Serial0/0/1 12.1.1.2 YES manual up up
라우터 RIP 설정
R2(config)# router rip
R2(config‐router)# network 2.2.2.0
R2(config‐router)# network 12.1.1.0
R2(config‐router)# network 23.1.1.0
[R3]
R3# show ip int brief
Interface IP‐Address OK? Method Status Protocol
GigabitEthernet0/0 3.3.3.1 YES manual up up
Serial0/0/0 31.1.1.3 YES manual up up
Serial0/0/1 23.1.1.3 YES manual up up
라우터 RIP 설정
R3(config)# router rip
R3(config‐router)# network 3.3.3.0
R3(config‐router)# network 31.1.1.0
R3(config‐router)# network 23.1.1.0