[GNS3 Labs. – Cisco] 라우팅 part 3 (Dynamic Routing – OSPF)

[GNS3 Lab. – Cisco] 라우팅 part 3 (Dynamic Routing – OSPF)

참고문서 : CCNA® Routing and Switching Study Guide – sybex

* 작업 환경
GNS3 vm 시뮬레이터
각 라우터는 IOU L3 스위치 이용.
필요한 최소한의 설정만 적용(비밀번호 등의 설정은 배제 하였음).

* 구성
이전 구성에, Boulder 라우터를 추가 했다.

* OSPF(Open Shortest Path First) – OSPF 프로토콜은 시스코를 포함한 다양한 네트워크 공급 업체에서 구현한 개방형 표준 라우팅 프로토콜로, link state 라우팅 프로토콜이다.

* 용어
Link : 링크는 주어진 네트워크에 할당 된 네트워크 또는 라우터 인터페이스다. 인터페이스가 OSPF 프로세스에 추가되면 링크로 간주된다. 이 링크 또는 인터페이스는 하나 이상의 IP 주소와 관련된 up 또는 down 상태 정보를 가진다.

Router ID(RID) : 라우터 ID (RID)는 라우터를 식별하는 데 사용되는 IP 주소이다. 시스코는 루프백 인터페이스가 설정되어 있으면, 루프백 인터페이스 주소를 RID로 사용하고, 설정되어 있지 않으면 활성된 인터페이스 주소 중 가장 높은(heighest) IP 주소를 RID로 사용한다.

Neighbor : Neighbor는 point to point serial 링크로 연결된 두 개의 라우터 처럼, 공용 네트워크에 인터페이스가 있는 둘 이상의 라우터이다. OSPF neighbor는 여러 공통 설정 옵션을 가지며 이러한 모든 옵션은 정확히 같은 방식으로 설정 되어야 한다. 옵션에는, Area ID, Stub area flag, Authentication password (if using one), Hello and Dead intervals 이 있다.

Adjacency(인접관계) : 경로 업데이트를 직접 교환 할 수있게 해주는 두 OSPF 라우터 간의 관계다.

Designated router(DR) : 멀티 엑세스 네트워크를 대표하는 라우터.

Backup designated router(BDR) : DR에 문제 생길경우 그 역할을 물려받는 라우터.

Hello protocol : 두 이웃 라우터 간에 인접관계(Adjacency)를 설정하고 유지한다.

Neighborship database : Hello 패킷이 표시된 모든 OSPF 라우터 목록.

Link State Advertisement(LSA) : LSA (Link State Advertisement)는 OSPF 라우터간에 공유되는 링크 상태 및 라우팅 정보가 포함 된 OSPF 데이터 패킷. OSPF 라우터는 인접성을 설정 한 라우터만 LSA 패킷을 교환한다.

OSPF area : OSPF Area는 연속적인 네트워크와 라우터의 그룹이다. 동일한 Area의 모든 라우터는 Area ID를 공유한다. 라우터는 둘 이상의 Area에 속할 수 있기 때문에 Area ID는 라우터의 특정 인터페이스와 연관된다.

Broadcast (multi-access) : 이더넷처럼 브로드 캐스트(멀티 액세스) 네트워크는 여러 장치가 같은 네트워크에 연결되거나 액세스 할 수있게 되어 단일 패킷이 네트워크의 모든 노드로 전달되는 브로드 캐스트 기능이 가능하다. OSPF에서, 멀티엑세스 네트워크에 브로드캐스트 하기위해 DR과 BDR을 반드시 선출해야 한다.
Nonbroadcast multi-access(NBMA) : NBMA 네트워크는 프레임 릴레이, X.25 및 비동기 전송 모드 (ATM)와 같은 네트워크다. 이러한 유형의 네트워크는 이더넷과 같은 브로드 캐스트 기능없이 다중 액세스를 허용한다.
Point-to-point : point-to-point는 단일 통신 경로를 제공하는 두 라우터 간의 직접 연결로 구성된 네트워크 토폴로지 유형이다. DR, BDR이 필요하지 않다.

Point-to-multipoint :   point-to-multipoint는 한 라우터의 단일 인터페이스와 여러 대상 라우터 사이에 일련의 연결로 구성된 네트워크 토폴로지 유형이다.

1. Part2에서 구성한 RIP 라우팅 삭제

* Core, Fox, Wolf 라우터 모두 동일

Core# conf t
Core(config)# no router rip

2. OSPF 설정

*Core 라우터
인터페이스 설정을 확인해 본다.

Core#show ip int brief
Interface                  IP-Address      OK? Method Status                Protocol
Ethernet0/0                10.10.10.1      YES manual up                    up
..
Serial2/0                  172.16.10.1     YES manual up                    up
Serial2/1                  172.16.10.5     YES manual up                    up
...

OSPF 설정

Core(config)#router ospf 100
Core(config-router)# network 10.10.10.1 0.0.0.0 area 0
Core(config-router)# network 172.16.10.1 0.0.0.0 area 0
Core(config-router)# network 172.16.10.5 0.0.0.0 area 0
Core(config-router)#end
Core#

위의 설정에서, 아래 172.16.10.0/30, 172.16.10.4/30 두 네트워크는 아래처럼 한 줄로 대신 할 수도 있다.

Core(config-router)#network 172.16.10.0 0.0.0.255 area 0

show ip route 명령어로 라우팅을 확인해보면, OSPF는 아직 적용되지 않았음을 볼 수 있다.

Core#sh 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
       i - IS-IS, su - IS-IS summary, 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, H - NHRP, l - LISP
       + - replicated route, % - next hop override

Gateway of last resort is not set

      10.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C        10.10.10.0/24 is directly connected, Ethernet0/0
L        10.10.10.1/32 is directly connected, Ethernet0/0
      172.16.0.0/16 is variably subnetted, 4 subnets, 2 masks
C        172.16.10.0/30 is directly connected, Serial2/0
L        172.16.10.1/32 is directly connected, Serial2/0
C        172.16.10.4/30 is directly connected, Serial2/1
L        172.16.10.5/32 is directly connected, Serial2/1

* Fox 라우터 설정
인터페이스 확인

Fox#sh ip int brief
Interface                  IP-Address      OK? Method Status                Protocol
Ethernet0/0                192.168.10.1    YES manual administratively down down
...
Serial2/0                  172.16.10.2     YES manual up                    up

OSPF 설정

Fox# conf t
Enter configuration commands, one per line.  End with CNTL/Z.
Fox(config)#router ospf 200
Fox(config-router)#network 192.168.10.1 0.0.0.0 area 0
Fox(config-router)#network 172.16.10.2 0.0.0.0 area 0
Fox(config-router)#

라우팅 확인

Fox# sh 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
       i - IS-IS, su - IS-IS summary, 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, H - NHRP, l - LISP
       + - replicated route, % - next hop override

Gateway of last resort is not set

      10.0.0.0/24 is subnetted, 1 subnets
O        10.10.10.0 [110/74] via 172.16.10.1, 00:00:05, Serial2/0
      172.16.0.0/16 is variably subnetted, 3 subnets, 2 masks
C        172.16.10.0/30 is directly connected, Serial2/0
L        172.16.10.2/32 is directly connected, Serial2/0
O        172.16.10.4/30 [110/128] via 172.16.10.1, 00:00:05, Serial2/0

* Core 라우터의 라우팅 확인
Fox 라우터의 OSPF가 설정되면 아래처럼 라우팅 정보가 교환됨을 확인 할 수 있다.

Core#sh 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
       i - IS-IS, su - IS-IS summary, 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, H - NHRP, l - LISP
       + - replicated route, % - next hop override

Gateway of last resort is not set

      10.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C        10.10.10.0/24 is directly connected, Ethernet0/0
L        10.10.10.1/32 is directly connected, Ethernet0/0
      172.16.0.0/16 is variably subnetted, 4 subnets, 2 masks
C        172.16.10.0/30 is directly connected, Serial2/0
L        172.16.10.1/32 is directly connected, Serial2/0
C        172.16.10.4/30 is directly connected, Serial2/1
L        172.16.10.5/32 is directly connected, Serial2/1
O     192.168.10.0/24 [110/74] via 172.16.10.2, 00:00:37, Serial2/0
Core#

* Wolf 라우터 설정
인터페이스 확인

Wolf#sh ip int brief
Interface                  IP-Address      OK? Method Status                Protocol
Ethernet0/0                192.168.20.1    YES manual up                    up
...
Serial2/1                  172.16.10.6     YES manual up                    up
Serial2/2                  unassigned      YES NVRAM  administratively down down

OSPF 라우팅 설정

Wolf#conf t
Enter configuration commands, one per line.  End with CNTL/Z.
Wolf(config)#router ospf 300
Wolf(config-router)#network 192.168.20.1 0.0.0.0 area 0
Wolf(config-router)#network 172.16.10.6 0.0.0.0 area 0
Wolf(config-router)#end
Wolf#

라우팅 확인

Wolf#sh 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
       i - IS-IS, su - IS-IS summary, 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, H - NHRP, l - LISP
       + - replicated route, % - next hop override

Gateway of last resort is not set

      10.0.0.0/24 is subnetted, 1 subnets
O        10.10.10.0 [110/74] via 172.16.10.5, 00:00:00, Serial2/1
      172.16.0.0/16 is variably subnetted, 3 subnets, 2 masks
O        172.16.10.0/30 [110/128] via 172.16.10.5, 00:00:00, Serial2/1
C        172.16.10.4/30 is directly connected, Serial2/1
L        172.16.10.6/32 is directly connected, Serial2/1
O     192.168.10.0/24 [110/138] via 172.16.10.5, 00:00:00, Serial2/1
      192.168.20.0/24 is variably subnetted, 2 subnets, 2 masks
C        192.168.20.0/24 is directly connected, Ethernet0/0
L        192.168.20.1/32 is directly connected, Ethernet0/0

* 모든 라우터 설정이 끝난후 시험
Wolf 라우터에서 Core 라우터의 e0/0 포트까지 ping 시험을 해 본다.

Wolf#ping 10.10.10.1
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 10.10.10.1, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 9/9/9 ms
Wolf#ping 192.168.10.2
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 192.168.10.2, timeout is 2 seconds:
.!!!!

VPC1 에서 VPC2까지 통신도 화인해 본다

VPCS> ping 192.168.20.2
84 bytes from 192.168.20.2 icmp_seq=1 ttl=61 time=19.235 ms
84 bytes from 192.168.20.2 icmp_seq=2 ttl=61 time=18.985 ms
84 bytes from 192.168.20.2 icmp_seq=3 ttl=61 time=16.256 ms
84 bytes from 192.168.20.2 icmp_seq=4 ttl=61 time=18.895 ms
84 bytes from 192.168.20.2 icmp_seq=5 ttl=61 time=18.868 ms

3. OSPF advertisement 차단
Wolf 라우터의 e0/1 포트가 OSPF를 사용하지 않는 네트워크에 연결되었다고 가정하면, e0/1 포트로는 OSPF advertisement 할 필요가 없다
아래와 같이 설정한다.

Wolf# conf t
Enter configuration commands, one per line.  End with CNTL/Z.
Wolf(config)#router ospf 300
Wolf(config-router)#passive
Wolf(config-router)#passive-interface e0/1
Wolf(config-router)#end
Wolf#

4. Core 라우터의 default Route 설정
Fox, Wolf 라우터에게 default route를 advertisement 하도록 Core 라우터를 설정한다. 이렇게 하면, Fox, Wolf에대해서 default route를 설정하지 않아도 되기때문이다.

Core#conf t
Enter configuration commands, one per line.  End with CNTL/Z.
Core(config)#ip route 0.0.0.0 0.0.0.0 e0/0
%Default route without gateway, if not a point-to-point interface, may impact performance
Core(config)#router ospf 100
Core(config-router)#default-information originate
Core(config-router)#end

라우팅을 확인해 보면, default route 가 static route로 설정된 것을 볼 수 있다.

ore#sh 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
       i - IS-IS, su - IS-IS summary, 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, H - NHRP, l - LISP
       + - replicated route, % - next hop override

Gateway of last resort is 0.0.0.0 to network 0.0.0.0

S*    0.0.0.0/0 is directly connected, Ethernet0/0
      10.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C        10.10.10.0/24 is directly connected, Ethernet0/0
L        10.10.10.1/32 is directly connected, Ethernet0/0
      172.16.0.0/16 is variably subnetted, 4 subnets, 2 masks
C        172.16.10.0/30 is directly connected, Serial2/0
L        172.16.10.1/32 is directly connected, Serial2/0
C        172.16.10.4/30 is directly connected, Serial2/1
L        172.16.10.5/32 is directly connected, Serial2/1
O     192.168.10.0/24 [110/74] via 172.16.10.2, 02:12:19, Serial2/0
O     192.168.20.0/24 [110/74] via 172.16.10.6, 02:08:43, Serial2/1
Core#

이제, 다른 라우터에서 OSPF 라우팅을 확인해 보면, 아래처럼 default route가 설정(O*E2 0.0.0.0/0 [110/1] via 172.16.10.1, 00:04:51, Serial2/0)된 것을 확인 할 수 있다.

Fox#sh 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
       i - IS-IS, su - IS-IS summary, 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, H - NHRP, l - LISP
       + - replicated route, % - next hop override

Gateway of last resort is 172.16.10.1 to network 0.0.0.0

O*E2  0.0.0.0/0 [110/1] via 172.16.10.1, 00:04:51, Serial2/0
      10.0.0.0/24 is subnetted, 1 subnets
O        10.10.10.0 [110/74] via 172.16.10.1, 00:26:06, Serial2/0
      172.16.0.0/16 is variably subnetted, 3 subnets, 2 masks
C        172.16.10.0/30 is directly connected, Serial2/0
L        172.16.10.2/32 is directly connected, Serial2/0
O        172.16.10.4/30 [110/128] via 172.16.10.1, 00:26:06, Serial2/0
      172.30.0.0/32 is subnetted, 1 subnets
C        172.30.1.2 is directly connected, Loopback0
      192.168.10.0/24 is variably subnetted, 2 subnets, 2 masks
C        192.168.10.0/24 is directly connected, Ethernet0/0
L        192.168.10.1/32 is directly connected, Ethernet0/0
O     192.168.20.0/24 [110/138] via 172.16.10.1, 00:26:06, Serial2/0

5. Boulder 라우터 설정(DR/BDR 확인용)

Router#config t
Router(config)#hostname Boulder
Boulder(config)#int f0/0
Boulder(config-if)#ip address 10.10.10.2 255.255.255.0
Boulder(config-if)#no shut
Boulder(config-if)#router ospf 2
Boulder(config-router)#network 10.0.0.0 0.255.255.255 area 0

6. 루프백 인터페이스(loopback interface) 설정
루프백인터페이스는 실제하는 것이 아니고, 가상의 논리적인 인터페이스이다.OSPF에 루프백인터페이스를 사용하는 큰 이유는 ospf 프로세스가 항상 동작하게 하는데 있고, 또한 ospf 구성을 확인하는데 있다.
라우터에 루프백인터페이스를 설정하지 않으면, 라우터 부팅시에 가장 높은 활성 IP주소가 라우터의 RID가 된다.
RID는 경로 Advertisement에 사용될뿐만 아니라 지정된 라우터(DR) 및 백업 지정 라우터(BDR)를 선출하는데도 사용된다. 이러한 지정된 라우터는 새 라우터가 나타나면 인접성을 만들고 LSA(Link-State Advertisement)를 교환하여 토폴로지 데이터베이스를 만든다.

Core 라우터의 RID는 아래처럼 확인 가능하다.

Core#sh ip ospf
 Routing Process "ospf 1" with ID 172.16.10.1
...
 Reference bandwidth unit is 100 mbps

 Routing Process "ospf 100" with ID 172.16.10.5
 Start time: 00:34:34.508, Time elapsed: 03:37:50.586
...

루프백 인터페이스를 설정한다.
Core 라우터 루프백 인터페이스 설정

Core# conf t
Enter configuration commands, one per line.  End with CNTL/Z.
Core(config)#int loopback
Core(config)#int loopback 0
Core(config-if)#ip address 172
*Dec 11 05:35:34.440: %LINK-3-UPDOWN: Interface Loopback0, changed state to up
*Dec 11 05:35:35.440: %LINEPROTO-5-UPDOWN: Line protocol on Interface Loopback0, changed state to up
Core(config-if)#ip address 172.30.1.1 255.255.255.255
Core(config-if)#end
Core#

Fox 라우터 루프백 인터페이스 설정

Fox#conf t
Enter configuration commands, one per line.  End with CNTL/Z.
Fox(config)#int loopback 0
Fox(config-if)#ip address 17
*Dec 11 05:38:16.862: %LINK-3-UPDOWN: Interface Loopback0, changed state to up
*Dec 11 05:38:17.869: %LINEPROTO-5-UPDOWN: Line protocol on Interface Loopback0, changed state to up
Fox(config-if)#ip address 172.30.1.2 255.255.255.255
Fox(config-if)#end
Fox#

Wolf 라우터 루프백 인터페이스 설정

Wolf#conf t
Enter configuration commands, one per line.  End with CNTL/Z.
Wolf(config)#int loopback 0
Wolf(config-if)#ip address 1
*Dec 11 05:40:16.998: %LINK-3-UPDOWN: Interface Loopback0, changed state to up
*Dec 11 05:40:17.999: %LINEPROTO-5-UPDOWN: Line protocol on Interface Loopback0, changed state to up
Wolf(config-if)#ip address 172.30.1.3 255.255.255.255
Wolf(config-if)#end
Wolf#

부팅후 Core 라우터의 OSPF RID를 확인해 보면, 아래처럼 루프백 인터페이스의 IP 주소로 바뀐 것을 볼 수 있다.

Core#sh ip ospf
 Routing Process "ospf 100" with ID 172.30.1.1
 ...

7. OSPF의 RID를 직접 지정하기
OSPF의 RID를 아래와 같이 직접 지정하면, 재부팅 없이도 즉시 RID를 바꿀 수 있으며, 이 방법이 최고의 우선순위를 가지게 된다.

Core#conf t
Enter configuration commands, one per line.  End with CNTL/Z.
Core(config)#router ospf 1
Core(config-router)#router-id 223.255.255.254
Core(config-router)#do clear ip ospf process
Reset ALL OSPF processes? [no]: yes
Core(config-router)#
*Dec 11 05:53:12.725: %OSPF-5-ADJCHG: Process 100, Nbr 192.168.20.1 on Serial2/1 from FULL to DOWN, Neighbor Down: Interface down or detached
*Dec 11 05:53:12.725: %OSPF-5-ADJCHG: Process 100, Nbr 192.168.10.1 on Serial2/0 from FULL to DOWN, Neighbor Down: Interface down or detached
*Dec 11 05:53:12.725: %OSPF-5-ADJCHG: Process 100, Nbr 10.10.10.2 on Ethernet0/0 from FULL to DOWN, Neighbor Down: Interface down or detached
*Dec 11 05:53:12.736: %OSPF-5-ADJCHG: Process 100, Nbr 10.10.10.2 on Ethernet0/0 from LOADING to FULL, Loading Done
*Dec 11 05:53:12.749: %OSPF-5-ADJCHG: Process 100, Nbr 192.168.20.1 on Serial2/1 from LOADING to FULL, Loading Done
*Dec 11 05:53:12.750: %OSPF-5-ADJCHG: Process 100, Nbr 192.168.10.1 on Serial2/0 from LOADING to FULL, Loading Done
Core(config-router)#end
Core#

RID가 바뀐것을 확인 할 수 있다.

Core#sh ip ospf
 Routing Process "ospf 1" with ID 223.255.255.254
 Start time: 00:00:05.314, Time elapsed: 00:09:48.546

8. OSPF 설정을 확인하는 몇 가지 방법
* show ip ospf 명령어로 ospf에 대한 모든 정보를 확인 할 수 있다.

Core#sh ip ospf
 Routing Process "ospf 100" with ID 172.30.1.1
 Start time: 00:00:05.314, Time elapsed: 00:36:03.154
 Supports only single TOS(TOS0) routes
 Supports opaque LSA
 Supports Link-local Signaling (LLS)
 Supports area transit capability
 Supports NSSA (compatible with RFC 3101)
 Event-log enabled, Maximum number of events: 1000, Mode: cyclic
 It is an autonomous system boundary router
 Redistributing External Routes from,
 Router is not originating router-LSAs with maximum metric
 Initial SPF schedule delay 5000 msecs
 Minimum hold time between two consecutive SPFs 10000 msecs
 Maximum wait time between two consecutive SPFs 10000 msecs
 Incremental-SPF disabled
 Minimum LSA interval 5 secs
 Minimum LSA arrival 1000 msecs
 LSA group pacing timer 240 secs
 Interface flood pacing timer 33 msecs
 Retransmission pacing timer 66 msecs
 Number of external LSA 1. Checksum Sum 0x00285A
 Number of opaque AS LSA 0. Checksum Sum 0x000000
 Number of DCbitless external and opaque AS LSA 0
 Number of DoNotAge external and opaque AS LSA 0
 Number of areas in this router is 1. 1 normal 0 stub 0 nssa
 Number of areas transit capable is 0
 External flood list length 0
 IETF NSF helper support enabled
 Cisco NSF helper support enabled
 Reference bandwidth unit is 100 mbps
    Area BACKBONE(0)
        Number of interfaces in this area is 3
        Area has no authentication
        SPF algorithm last executed 00:05:35.882 ago
        SPF algorithm executed 3 times
        Area ranges are
        Number of LSA 5. Checksum Sum 0x0312E7
        Number of opaque link LSA 0. Checksum Sum 0x000000
        Number of DCbitless LSA 0
        Number of indication LSA 0
        Number of DoNotAge LSA 0
        Flood list length 0

* show ip ospf database 명령을 사용하면 AS에있는 라우터 수와 인접 라우터 ID에 대한 정보를 얻을 수 있다. 이 명령은 OSPF 라우터를 표시하지만 AS의 모든 링크가 표시되지는 않는다.

Core#sh ip ospf database

            OSPF Router with ID (172.30.1.1) (Process ID 100)

                Router Link States (Area 0)

Link ID         ADV Router      Age         Seq#       Checksum Link count
10.10.10.2      10.10.10.2      277         0x80000014 0x00781E 1
172.30.1.1      172.30.1.1      411         0x80000004 0x0003F9 5
192.168.10.1    192.168.10.1    88          0x8000000E 0x00B80F 3
192.168.20.1    192.168.20.1    1969        0x8000000B 0x00E5BE 3

                Net Link States (Area 0)

Link ID         ADV Router      Age         Seq#       Checksum
10.10.10.2      10.10.10.2      277         0x80000011 0x00F903

                Type-5 AS External Link States

Link ID         ADV Router      Age         Seq#       Checksum Tag
0.0.0.0         172.30.1.1      412         0x80000001 0x00285A 100

* show ip ospf interface 명령은 모든 인터페이스 관련 OSPF 정보를 보여준다.

Core#sh ip ospf int e0/0
Ethernet0/0 is up, line protocol is up
  Internet Address 10.10.10.1/24, Area 0, Attached via Network Statement
  Process ID 100, Router ID 172.30.1.1, Network Type BROADCAST, Cost: 10
  Topology-MTID    Cost    Disabled    Shutdown      Topology Name
        0           10        no          no            Base
  Transmit Delay is 1 sec, State BDR, Priority 1
  Designated Router (ID) 10.10.10.2, Interface address 10.10.10.2
  Backup Designated router (ID) 172.30.1.1, Interface address 10.10.10.1
  Timer intervals configured, Hello 10, Dead 40, Wait 40, Retransmit 5
    oob-resync timeout 40
    Hello due in 00:00:04
  Supports Link-local Signaling (LLS)
  Cisco NSF helper support enabled
  IETF NSF helper support enabled
  Index 1/1, flood queue length 0
  Next 0x0(0)/0x0(0)
  Last flood scan length is 1, maximum is 1
  Last flood scan time is 0 msec, maximum is 0 msec
  Neighbor Count is 1, Adjacent neighbor count is 1
    Adjacent with neighbor 10.10.10.2  (Designated Router)
  Suppress hello for 0 neighbor(s)
Core#

* show ip ospf neighbor 명령은 인접 노드 및 인접 상태와 관련된 관련 OSPF 정보를 요약하기 때문에 매우 유용하다. DR 또는 BDR이 있으면 해당 정보도 표시된다.

Core#sh ip ospf neighbor

Neighbor ID     Pri   State           Dead Time   Address         Interface
192.168.20.1      0   FULL/  -        00:00:36    172.16.10.6     Serial2/1
192.168.10.1      0   FULL/  -        00:00:39    172.16.10.2     Serial2/0
10.10.10.2        1   FULL/DR         00:00:32    10.10.10.2      Ethernet0/0


Boulder#sh ip ospf neighbor

Neighbor ID     Pri   State           Dead Time   Address         Interface
172.30.1.1        1   FULL/BDR        00:00:32    10.10.10.1      Ethernet0/0
Boulder#

* show ip protocols 명령은 현재 실행중인 모든 프로토콜의 실제 작동에 대한 개요를 제공한다.

Core#sh ip protocols
*** IP Routing is NSF aware ***

Routing Protocol is "ospf 100"
  Outgoing update filter list for all interfaces is not set
  Incoming update filter list for all interfaces is not set
  Router ID 172.30.1.1
  It is an autonomous system boundary router
 Redistributing External Routes from,
  Number of areas in this router is 1. 1 normal 0 stub 0 nssa
  Maximum path: 4
  Routing for Networks:
    10.10.10.1 0.0.0.0 area 0
    172.16.10.0 0.0.0.255 area 0
  Routing Information Sources:
    Gateway         Distance      Last Update
    192.168.10.1         110      00:09:15
    192.168.20.1         110      00:09:15
  Distance: (default is 110)

9. 각 라우터의 설정값은 아래와 같다.

* Core 라우터 설정

Core#sh run
Building configuration...

Current configuration : 2056 bytes
!
! Last configuration change at 06:14:40 UTC Mon Dec 11 2017
version 15.2
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname Core
!
boot-start-marker
boot-end-marker
!
!
!
no aaa new-model
mmi polling-interval 60
no mmi auto-configure
no mmi pvc
mmi snmp-timeout 180
no ip icmp rate-limit unreachable
!
!
!
!
!
!
no ip domain lookup
ip cef
no ipv6 cef
!
multilink bundle-name authenticated
!
!
!
!
!
!
!
!
!
redundancy
!
!
ip tcp synwait-time 5
!
!
!
!
!
!
!
!
!
!
!
!
interface Loopback0
 ip address 172.30.1.1 255.255.255.255
!
interface Ethernet0/0
 ip address 10.10.10.1 255.255.255.0
!
interface Ethernet0/1
 no ip address
 shutdown
!
interface Ethernet0/2
 no ip address
 shutdown
!
interface Ethernet0/3
 no ip address
 shutdown
!
interface Ethernet1/0
 no ip address
 shutdown
!
interface Ethernet1/1
 no ip address
 shutdown
!
interface Ethernet1/2
 no ip address
 shutdown
!
interface Ethernet1/3
 no ip address
 shutdown
!
interface Serial2/0
 ip address 172.16.10.1 255.255.255.252
 serial restart-delay 0
!
interface Serial2/1
 ip address 172.16.10.5 255.255.255.252
 serial restart-delay 0
!
interface Serial2/2
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/3
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial3/0
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial3/1
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial3/2
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial3/3
 no ip address
 shutdown
 serial restart-delay 0
!
router ospf 100
 network 10.10.10.1 0.0.0.0 area 0
 network 172.16.10.0 0.0.0.255 area 0
 default-information originate
!
ip forward-protocol nd
!
!
no ip http server
no ip http secure-server
ip route 0.0.0.0 0.0.0.0 Ethernet0/0
!
!
!
!
control-plane
!
!
!
!
!
!
!
line con 0
 exec-timeout 0 0
 privilege level 15
 logging synchronous
line aux 0
 exec-timeout 0 0
 privilege level 15
 logging synchronous
line vty 0 4
 login
 transport input all
!
!
end

* Fox 라우터 설정

Fox#sh run
Building configuration...

Current configuration : 1974 bytes
!
! Last configuration change at 05:39:02 UTC Mon Dec 11 2017
version 15.2
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname Fox
!
boot-start-marker
boot-end-marker
!
!
!
no aaa new-model
mmi polling-interval 60
no mmi auto-configure
no mmi pvc
mmi snmp-timeout 180
no ip icmp rate-limit unreachable
!
!
!
!
!
!
no ip domain lookup
ip cef
no ipv6 cef
!
multilink bundle-name authenticated
!
!
!
!
!
!
!
!
!
redundancy
!
!
ip tcp synwait-time 5
!
!
!
!
!
!
!
!
!
!
!
!
interface Loopback0
 ip address 172.30.1.2 255.255.255.255
!
interface Ethernet0/0
 ip address 192.168.10.1 255.255.255.0
!
interface Ethernet0/1
 no ip address
 shutdown
!
interface Ethernet0/2
 no ip address
 shutdown
!
interface Ethernet0/3
 no ip address
 shutdown
!
interface Ethernet1/0
 no ip address
 shutdown
!
interface Ethernet1/1
 no ip address
 shutdown
!
interface Ethernet1/2
 no ip address
 shutdown
!
interface Ethernet1/3
 no ip address
 shutdown
!
interface Serial2/0
 ip address 172.16.10.2 255.255.255.252
 serial restart-delay 0
!
interface Serial2/1
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/2
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/3
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial3/0
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial3/1
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial3/2
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial3/3
 no ip address
 shutdown
 serial restart-delay 0
!
router ospf 200
 network 172.16.10.2 0.0.0.0 area 0
 network 192.168.10.1 0.0.0.0 area 0
!
ip forward-protocol nd
!
!
no ip http server
no ip http secure-server
!
!
!
!
control-plane
!
!
!
!
!
!
!
line con 0
 exec-timeout 0 0
 privilege level 15
 logging synchronous
line aux 0
 exec-timeout 0 0
 privilege level 15
 logging synchronous
line vty 0 4
 login
 transport input all
!
!
end

* Wolf 라우터 설정

Wolf#sh run
Building configuration...

Current configuration : 2006 bytes
!
! Last configuration change at 05:40:30 UTC Mon Dec 11 2017
version 15.2
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname Wolf
!
boot-start-marker
boot-end-marker
!
!
!
no aaa new-model
mmi polling-interval 60
no mmi auto-configure
no mmi pvc
mmi snmp-timeout 180
no ip icmp rate-limit unreachable
!
!
!
!
!
!
no ip domain lookup
ip cef
no ipv6 cef
!
multilink bundle-name authenticated
!
!
!
!
!
!
!
!
!
redundancy
!
!
ip tcp synwait-time 5
!
!
!
!
!
!
!
!
!
!
!
!
interface Loopback0
 ip address 172.30.1.3 255.255.255.255
!
interface Ethernet0/0
 ip address 192.168.20.1 255.255.255.0
!
interface Ethernet0/1
 no ip address
 shutdown
!
interface Ethernet0/2
 no ip address
 shutdown
!
interface Ethernet0/3
 no ip address
 shutdown
!
interface Ethernet1/0
 no ip address
 shutdown
!
interface Ethernet1/1
 no ip address
 shutdown
!
interface Ethernet1/2
 no ip address
 shutdown
!
interface Ethernet1/3
 no ip address
 shutdown
!
interface Serial2/0
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/1
 ip address 172.16.10.6 255.255.255.252
 serial restart-delay 0
!
interface Serial2/2
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/3
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial3/0
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial3/1
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial3/2
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial3/3
 no ip address
 shutdown
 serial restart-delay 0
!
router ospf 300
 passive-interface Ethernet0/1
 network 172.16.10.6 0.0.0.0 area 0
 network 192.168.20.1 0.0.0.0 area 0
!
ip forward-protocol nd
!
!
no ip http server
no ip http secure-server
!
!
!
!
control-plane
!
!
!
!
!
!
!
line con 0
 exec-timeout 0 0
 privilege level 15
 logging synchronous
line aux 0
 exec-timeout 0 0
 privilege level 15
 logging synchronous
line vty 0 4
 login
 transport input all
!
!
end

* Boulder 라우터 설정

Boulder#sh run
Building configuration...

Current configuration : 1832 bytes
!
! Last configuration change at 01:56:29 UTC Mon Dec 11 2017
version 15.2
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname Boulder
!
boot-start-marker
boot-end-marker
!
!
!
no aaa new-model
mmi polling-interval 60
no mmi auto-configure
no mmi pvc
mmi snmp-timeout 180
no ip icmp rate-limit unreachable
!
!
!
!
!
!
no ip domain lookup
ip cef
no ipv6 cef
!
multilink bundle-name authenticated
!
!
!
!
!
!
!
!
!
redundancy
!
!
ip tcp synwait-time 5
!
!
!
!
!
!
!
!
!
!
!
!
interface Ethernet0/0
 ip address 10.10.10.2 255.255.255.0
!
interface Ethernet0/1
 no ip address
!
interface Ethernet0/2
 no ip address
!
interface Ethernet0/3
 no ip address
!
interface Ethernet1/0
 no ip address
 shutdown
!
interface Ethernet1/1
 no ip address
 shutdown
!
interface Ethernet1/2
 no ip address
 shutdown
!
interface Ethernet1/3
 no ip address
 shutdown
!
interface Serial2/0
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/1
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/2
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial2/3
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial3/0
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial3/1
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial3/2
 no ip address
 shutdown
 serial restart-delay 0
!
interface Serial3/3
 no ip address
 shutdown
 serial restart-delay 0
!
router ospf 2
 network 10.10.10.0 0.0.0.255 area 0
!
ip forward-protocol nd
!
!
no ip http server
no ip http secure-server
!
!
!
!
control-plane
!
!
!
!
!
!
!
line con 0
 exec-timeout 0 0
 privilege level 15
 logging synchronous
line aux 0
 exec-timeout 0 0
 privilege level 15
 logging synchronous
line vty 0 4
 login
 transport input all
!
!
end

답글 남기기

Your email address will not be published.