실습 목표
좌측 구간에는 RIP을 활용하여 라우팅을 한다.
우측 구간에는 OSPF를 활용하여 라우팅을 한다.
재분배를 활용해 양쪽간에 통신이 가능케 한다.
중앙 라우터 설정
A(config)#int fa0/1
A(config-if)#ip add 192.168.1.2 255.255.255.0
A(config-if)#no sh
A(config-if)#int fa0/0
A(config-if)#ip add 192.168.2.1 255.255.255.0
A(config-if)#no sh
좌측 RIP 라우터 설정
RIP(config)#int fa0/0
RIP(config-if)#ip add 192.168.1.1 255.255.255.0
RIP(config-if)#no sh
RIP(config-if)#int fa0/1
RIP(config-if)#ip add 192.168.3.1 255.255.255.0
RIP(config-if)#no sh
RIP(config-if)#ex
RIP(config)#router rip
RIP(config-router)#network 192.168.1.0
RIP(config-router)#network 192.168.3.0
우측 OSPF 라우터 설정
OSPF(config)#int fa0/0
OSPF(config-if)#ip add 192.168.2.2 255.255.255.0
OSPF(config-if)#no sh
OSPF(config-if)#int fa0/1
OSPF(config-if)#ip add 192.168.4.1 255.255.255.0
OSPF(config-if)#no sh
OSPF(config-if)#router ospf 1
OSPF(config-router)#network 192.168.2.2 0.0.0.0 area 1
OSPF(config-router)#network 192.168.4.1 0.0.0.0 area 1
192.168.1.0/24 is variably subnetted, 2 subnets, 2 masks
C 192.168.1.0/24 is directly connected, FastEthernet0/1
L 192.168.1.2/32 is directly connected, FastEthernet0/1
192.168.2.0/24 is variably subnetted, 2 subnets, 2 masks
C 192.168.2.0/24 is directly connected, FastEthernet0/0
L 192.168.2.1/32 is directly connected, FastEthernet0/0
R 192.168.3.0/24 [120/1] via 192.168.1.1, 00:00:06, FastEthernet0/1
O 192.168.4.0/24 [110/2] via 192.168.2.2, 00:03:31, FastEthernet0/0
중앙 라우터의 라우팅 테이블이다.
OSPF에 대한 정보와 RIP에 대한 정보를 알고 있다.
192.168.2.0/24 is variably subnetted, 2 subnets, 2 masks
C 192.168.2.0/24 is directly connected, FastEthernet0/0
L 192.168.2.2/32 is directly connected, FastEthernet0/0
192.168.4.0/24 is variably subnetted, 2 subnets, 2 masks
C 192.168.4.0/24 is directly connected, FastEthernet0/1
L 192.168.4.1/32 is directly connected, FastEthernet0/1
하지만 OSPF 라우터의 라우팅 테이블을 확인한 결과, RIP에 대한 정보는 찾아볼 수 없다.
A(config-router)#router rip
A(config-router)#redistribute ospf 1 metric 5
A(config-router)#router ospf 1
A(config-router)#redistribute rip subnets
중앙 라우터에서 rip을 ospf에 대해 재분배, ospf를 rip에 대해 재분배를 해 주었다.
O E2 192.168.1.0/24 [110/20] via 192.168.2.1, 00:00:17, FastEthernet0/0
192.168.2.0/24 is variably subnetted, 2 subnets, 2 masks
C 192.168.2.0/24 is directly connected, FastEthernet0/0
L 192.168.2.2/32 is directly connected, FastEthernet0/0
O E2 192.168.3.0/24 [110/20] via 192.168.2.1, 00:00:17, FastEthernet0/0
192.168.4.0/24 is variably subnetted, 2 subnets, 2 masks
C 192.168.4.0/24 is directly connected, FastEthernet0/1
L 192.168.4.1/32 is directly connected, FastEthernet0/1
>> OSPF의 라우팅 테이블을 확인한 결과, O E2로 RIP라우터의 정보를 받을 수 있다는 것을 확인할 수 있었다.
양 쪽에 각각 호스트를 추가하여
192.168.3.100/24
GW 192.168.3.1
192.168.4.100/24
GW 192.168.4.1
핑테스트를 해본 결과 서로간의 통신이 원활하다는 것을 알 수 있다.
재분배에 대해서 알아보았으며, RIP과 OSPF 이외에 다른 라우팅에도 적용이 가능하다.
'시스코 > 시스코-실기' 카테고리의 다른 글
ACL 실습 - 요구사항 (1) ~ (4) (0) | 2022.01.12 |
---|---|
OSPF와 ACL을 적용한 토폴로지, 특정 호스트만 허용하기 (0) | 2022.01.12 |
동적 라우팅 - OSPF - (0) | 2022.01.10 |
동적 라우팅 - OSPF (0) | 2022.01.10 |
종합 실습 - SVI, EIGRP, 이더채널(etherchannel) (0) | 2022.01.10 |