본문 바로가기
Network tech/IP(Internet Protocol)

[Router] 명령어로 라우터 구성하기

by 어깨 :) 2023. 7. 31.
728x90

라우터를 설정하는 과정은 네트워크를 구성하고 관리하는 중요한 단계입니다. 그러므로 하나씩 차근차근 진행해 보도록 하겠습니다.

 

그럼 본격적으로 명령어를 가지고 실제로 라우터를 구성해 보겠습니다.

라우터 명령어
R1 Router>enable
Router#configrue terminal
Router(config)#hostname R1
R1(config)#interface fastethernet 0/0
R1(config-if)#no shutdown
R1(config-if)#ip address 10.10.1.1 255.255.255.0
R1(config-if)#exit
R1(config)#interface fastethernet 0/1
R1(config-if)#no shutdown
R1(config-if)#ip address 10.10.2.1 255.255.255.0
R1(config-if)#exit
R1(config)#interface fastethernet 1/0
R1(config-if)#no shutdown
R1(config-if)#ip address 10.10.3.1 255.255.255.0
R2 Router>enable
Router#configrue terminal
Router(config)#hostname R2
R2(config)#interface fastethernet 0/0
R2(config-if)#no shutdown
R2(config-if)#ip address 10.10.1.2 255.255.255.0
R2(config-if)#exit
R2(config)#interface fastethernet 0/1
R2(config-if)#no shutdown
R2(config-if)#ip address 10.10.4.1 255.255.255.0
R2(config-if)#exit
R2(config)#interface fastethernet 1/0
R2(config-if)#no shutdown
R2(config-if)#ip address 10.10.5.1 255.255.255.0

 


 

 

먼저, 라우터에 접속하여 설정을 변경할 수 있도록 특권 모드로 전환해야 합니다. 다음 명령어를 사용하여 특권 모드로 진입합니다.

 

Router> enable

 

 


특권 모드로 진입했다면, 이제 설정을 변경하기 위해 설정 모드로 들어갑니다. 다음 명령어를 사용합니다.

 

Router#configrue terminal

 

 


라우터의 호스트 이름을 설정해 줍니다. 예를 들어, "R1"이라는 이름을 사용하려면 다음과 같이 입력합니다.

 

Router(config)#hostname R1

 



 


 

 

 

이상으로 라우터 명령어 입력을 해봤습니다.

도움이 되시길 바라면서 마치겠습니다.

감사합니다.

728x90