관리 메뉴

개발 노트

3/30 5주차 : RIP와 Passive interface 본문

학부 공부 : 21.03.02~06.20/인터넷 이론 및 실습

3/30 5주차 : RIP와 Passive interface

hayoung.dev 2021. 4. 19. 03:51

[RIP]

 

RIP는 사람이 직접 설정하지 않아도 알아서 라우터를 자신들끼리 주고받는다.

RIP의 단점은 속도가 느려진다. 그래서 홉 계수를 15로 제한한다.

16은 무한대로 간주되고 도달할 수 없는 네트워크가 된다.

1. PC와 Switch끼리는 전부 1/0/1로 연결

2. Switch 간에는 구성도와 같이 연결

3. R1 CLI 설정

Switch>enable
Switch#config t
Enter configuration commands, one per line.  End with CNTL/Z.
Switch(config)#hostname R1
R1(config)#ip routing
R1(config)#inte
R1(config)#interface Gi
R1(config)#interface GigabitEthernet 1/0/1
R1(config-if)#no switchport
R1(config-if)#
%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet1/0/1, changed state to down

%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet1/0/1, changed state to up

R1(config-if)#ip address 211.114.1.1 255.255.255.0
R1(config-if)#interface GigabitEthernet 1/0/2
R1(config-if)#no switchport
R1(config-if)#
%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet1/0/2, changed state to down

%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet1/0/2, changed state to up

R1(config-if)#ip address 211.114.6.2 255.255.255.0
R1(config-if)#interface GigabitEthernet 1/0/3
R1(config-if)#no switchport
R1(config-if)#
%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet1/0/3, changed state to down

%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet1/0/3, changed state to up

R1(config-if)#ip address 211.114.2.1 255.255.255.0
R1(config-if)#exit
R1(config)#router rip
R1(config-router)#network 211.114.1.0
R1(config-router)#network 211.114.2.0
R1(config-router)#network 211.114.6.0
R1(config-router)#^Z
R1#
%SYS-5-CONFIG_I: Configured from console by console

R1#show running-config

...

end


R1#write memory
Building configuration...
Compressed configuration from 7383 bytes to 3601 bytes[OK]
[OK]

결과

라우터의 라우팅 테이블

 

4. R2 CLI 설정

Switch>enable
Switch#config t
Enter configuration commands, one per line.  End with CNTL/Z.
Switch(config)#hostname R2
R2(config)#ip routing
R2(config)#inte
R2(config)#interface Gi
R2(config)#interface GigabitEthernet 1/0/1
R2(config-if)#no switchport
R2(config-if)#
%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet1/0/1, changed state to down

%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet1/0/1, changed state to up

R2(config-if)#ip address 211.114.3.1 255.255.255.0
R2(config-if)#interface GigabitEthernet 1/0/2
R2(config-if)#no sw
R2(config-if)#no switchport 
R2(config-if)#
%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet1/0/2, changed state to down

%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet1/0/2, changed state to up

R2(config-if)#ip address 211.114.2.2 255.255.255.0
R2(config-if)#interface GigabitEthernet 1/0/3
R2(config-if)#no switchport
R2(config-if)#
%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet1/0/3, changed state to down

%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet1/0/3, changed state to up

R2(config-if)#ip address 211.114.4.1 255.255.255.0
R2(config-if)#^Z
R2#
%SYS-5-CONFIG_I: Configured from console by console

R2#config t
Enter configuration commands, one per line.  End with CNTL/Z.
R2(config)#router rip
R2(config-router)#network 211.114.3.0
R2(config-router)#network 211.114.2.0
R2(config-router)#network 211.114.4.0
R2(config-router)#^Z
R2#
%SYS-5-CONFIG_I: Configured from console by console

R2#show running-config

...


R2# write memory
Building configuration...
Compressed configuration from 7383 bytes to 3601 bytes[OK]
[OK]

결과

 

라우터의 라우팅 테이블

 

 

5. R3 CLI 설정

Switch>enable
Switch#config t
Enter configuration commands, one per line.  End with CNTL/Z.
Switch(config)#hostname R3
R3(config)#ip routing
R3(config)#in
R3(config)#interface Gi
R3(config)#interface GigabitEthernet 1/0/1
R3(config-if)#no switchport
R3(config-if)#
%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet1/0/1, changed state to down

%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet1/0/1, changed state to up

R3(config-if)#ip address 211.114.5.1 255.255.255.0
R3(config-if)#interface GigabitEthernet 1/0/2
R3(config-if)#no switchport
R3(config-if)#
%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet1/0/2, changed state to down

%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet1/0/2, changed state to up

R3(config-if)#ip address 211.114.4.2 255.255.255.0
R3(config-if)#interface GigabitEthernet 1/0/3
R3(config-if)#no switchport
R3(config-if)#
%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet1/0/3, changed state to down

%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet1/0/3, changed state to up

R3(config-if)#ip address 211.114.6.1 255.255.255.0
R3(config-if)#exit
R3(config)#router rip
R3(config-router)#network 211.114.5.0
R3(config-router)#network 211.114.4.0
R3(config-router)#network 211.114.6.0
R3(config-router)#^Z
R3#
%SYS-5-CONFIG_I: Configured from console by console

R3#show running-config

...


R3# write memory
Building configuration...
Compressed configuration from 7383 bytes to 3601 bytes[OK]
[OK]

결과

 

라우터의 라우팅 테이블

 

 

 

6. PC1 설정

7. PC2 설정

8. PC3 설정

 

9. Ping 테스트

 

 

[Passive interface]

1. R1

Switch>enable
Switch#config t
Enter configuration commands, one per line.  End with CNTL/Z.
Switch(config)#hostname R1
R1(config)#ip routing
R1(config)#int
R1(config)#interface Gi
R1(config)#interface GigabitEthernet 1/0/1
R1(config-if)#no s
R1(config-if)#no switchport
R1(config-if)#
%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet1/0/1, changed state to down

%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet1/0/1, changed state to up

R1(config-if)#ip address 200.200.3.2 255.255.255.0
R1(config-if)#interface GigabitEthernet 1/0/2
R1(config-if)#no switchport
R1(config-if)#
%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet1/0/2, changed state to down

%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet1/0/2, changed state to up

R1(config-if)#ip address 200.200.1.1 255.255.255.0
R1(config-if)#^Z
R1#
%SYS-5-CONFIG_I: Configured from console by console

R1#config t
Enter configuration commands, one per line.  End with CNTL/Z.
R1(config)#router rip
R1(config-router)#network 200.200.1.0
R1(config-router)#network 200.200.3.0
R1(config-router)#^Z
R1#
%SYS-5-CONFIG_I: Configured from console by console

R1#show running-config

...

R1#write memory

결과

 

라우팅 테이블

2. R2

Switch>enable
Switch#config t
Enter configuration commands, one per line.  End with CNTL/Z.
Switch(config)#ip routing
Switch(config)#int
Switch(config)#interface G
Switch(config)#interface GigabitEthernet 1/0/1
Switch(config-if)#no switchport
Switch(config-if)#
%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet1/0/1, changed state to down

%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet1/0/1, changed state to up

Switch(config-if)#ip address 200.200.1.2 255.255.255.0
Switch(config-if)#int
Switch(config-if)#interface GigabitEthernet 1/0/2
Switch(config-if)#no switchport
Switch(config-if)#
%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet1/0/2, changed state to down

%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet1/0/2, changed state to up

Switch(config-if)#ip address 200.200.2.1 255.255.255.0
Switch(config-if)#^Z
Switch#
%SYS-5-CONFIG_I: Configured from console by console

Switch#config t
Enter configuration commands, one per line.  End with CNTL/Z.
Switch(config)#router rip
Switch(config-router)#network 200.200.1.0
Switch(config-router)#network 200.200.2.0
Switch(config-router)#^Z
Switch#
%SYS-5-CONFIG_I: Configured from console by console

Switch#write memory
Building configuration...
Compressed configuration from 7383 bytes to 3601 bytes[OK]
[OK]
Switch#show running-config

결과

 

라우팅 테이블

 

 

 

3. R3

Switch>enable
Switch#config t
Enter configuration commands, one per line.  End with CNTL/Z.
Switch(config)#ip routing
Switch(config)#in
Switch(config)#interface Gi
Switch(config)#interface GigabitEthernet 1/0/1
Switch(config-if)#no switchport
Switch(config-if)#
%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet1/0/1, changed state to down

%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet1/0/1, changed state to up

Switch(config-if)#ip address 200.200.2.2 255.255.255.0
Switch(config-if)#interface GigabitEthernet 1/0/2
Switch(config-if)#no switchport
Switch(config-if)#
%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet1/0/2, changed state to down

%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet1/0/2, changed state to up

Switch(config-if)#ip address 200.200.3.1 255.255.255.0
Switch(config-if)#^Z
Switch#
%SYS-5-CONFIG_I: Configured from console by console

Switch#config t
Enter configuration commands, one per line.  End with CNTL/Z.
Switch(config)#router rip
Switch(config-router)#network 200.200.2.0
Switch(config-router)#network 200.200.3.0
Switch(config-router)#^Z
Switch#
%SYS-5-CONFIG_I: Configured from console by console

Switch#write memory
Building configuration...
Compressed configuration from 7383 bytes to 3601 bytes[OK]
[OK]
Switch#show running-config

결과

 

라우팅 테이블

반응형