본문 바로가기
CCNA

CCNA Router Static

by 북한산산적 2011. 12. 17.



router setting

--------------------------------
기본설정


Router (config)# no ip domain-lookup // 도메인을 찾지 말아라 (명령어를 잘못 쳤을때 도메인으로 인식하지 말

아라)

Router(config)#line console 0

Router(config-line)#exec-timeout 0 0 // 타임아웃 되어서 접속종료하지 말아라

Router(config-line)#logging synchronous


--------------------------------------


--------------------------------------
172.16.1.  000       0 0000

N = 3bit

              000       0 0000     0
              000       1 1111     31
---------------------------------------
              001       0 0000     32
              001       1 1111     63

              010       0 0000     64
              010       1 1111     95

              011       0 0000     96
              011       1 1111    127

              100       0 0000    128
              100       1 1111    159

              101       0 0000    160
              101      1 1111     191

              110       0 0000    192
              110       1 1111    223
---------------------------------------
              111       0 0000    223
              111       1 1111    255

----------------------------------------


Router> show version

Router> enable

Router#show running-config

Router#?

xec commands:
  <1-99>      Session number to resume
  auto        Exec level Automation
  clear       Reset functions
  clock       Manage the system clock
  configure   Enter configuration mode
  connect     Open a terminal connection
  copy        Copy from one file to another
  debug       Debugging functions (see also 'undebug')
  delete      Delete a file
  dir         List files on a filesystem
  disable     Turn off privileged commands
  disconnect  Disconnect an existing network connection
  enable      Turn on privileged commands
  erase       Erase a filesystem
  exit        Exit from the EXEC
  logout      Exit from the EXEC
  mkdir       Create new directory
  more        Display the contents of a file
  no          Disable debugging informations
  ping        Send echo messages
  reload      Halt and perform a cold restart
  resume      Resume an active network connection

Router#configure terminal
Enter configuration commands, one per line.  End with CNTL/Z.
Router(config)#

Router (config)# no ip domain-lookup // 도메인을 찾지 말아라

Router(config)#line console 0

Router(config-line)#exec-timeout 0 0 // 타임아웃 되어서 접속종료하지 말아라

Router(config-line)#logging synchronous

(config)#hostname R1 // router 이름 바꾸기

R1(config)#


R1#show history
   show interfaces Ethernet F 0/0
   show interfaces Ethernet 0/0/0
   show interfaces Ethernet 0/
   show interfaces Ethernet 0/0
  configure
  show interfaces FastEthernet 0/0
  configure
  configure terminal
  history
  show history


R1#terminal history size 3 // 히스토리 사이즈 3개만 출력


R1#copy running-config startup-config  // 설정 내용 저장 하기  기본적인 장비는 ram 에 저장이 되기 때문에

리붓 하게 되면 설정 내용이 날라 간다.

Destination filename [startup-config]?
Building configuration...
[OK]
R1#reload

 

R1#configure terminal
Enter configuration commands, one per line.  End with CNTL/Z.
R1(config)#inter
R1(config)#interface fa
R1(config)#interface fastEthernet 0/0
R1(config)#interface fastEthernet 0/0  // 라우터의 FastEternet 0/0 설정


R1(config-if)#no shutdown // fastethernet 활성화

%LINK-5-CHANGED: Interface FastEthernet0/0, changed state to up

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

 

R1(config-if)#ip address 172.16.1.33 255.255.255.224 // 아이피 설정

R1(config-if)#int s0/0

R1(config-if)#clock rate 64000 // dce 에서 넣지만 그냥 넣어 준다.
R1(config-if)#

설정 내용 보기

R1(config-if)#end

R1#show running-config // 라우터 설정 확인

 

interface FastEthernet0/0
 ip address 172.16.1.33 255.255.255.224
 duplex auto 
 speed auto
!
interface FastEthernet0/1
 no ip address
 duplex auto
 speed auto
 shutdown
!
interface Serial0/0
 ip address 172.16.1.129 255.255.255.224
!
interface Serial0/1

 

R1#configure terminal
Enter configuration commands, one per line.  End with CNTL/Z.
R1(config)#inter
R1(config)#interface fa
R1(config)#interface fastEthernet 0/0
R1(config-if)#duplex
R1(config-if)#duplex ?
  auto  Enable AUTO duplex configuration
  full  Force full duplex operation
  half  Force half-duplex operation
R1(config-if)#duplex full


R1(config-if)#speed ?
  10    Force 10 Mbps operation
  100   Force 100 Mbps operation
  auto  Enable AUTO speed configuration

 


R1#show ip interface brief     // 인터페이스에 대한 각각의 아이피 설정 정보를 볼수 있다.
Interface              IP-Address      OK? Method Status                Protocol
 
FastEthernet0/0        172.16.1.33     YES manual up                    up
 
FastEthernet0/1        unassigned      YES NVRAM  administratively down down
 
Serial0/0              172.16.1.129    YES manual down                  down
 
Serial0/1              unassigned      YES NVRAM  administratively down down
 
Serial0/2              unassigned      YES NVRAM  administratively down down
 
Serial0/3              unassigned      YES NVRAM  administratively down down
 
FastEthernet1/0        unassigned      YES NVRAM  administratively down down
 
FastEthernet1/1        unassigned      YES NVRAM  administratively down down

 

administratively down  //  쓸수 없는 상태

Serial0/0              172.16.1.129    YES manual down                  down // 통신을 할수 없는 상태


R2 router 에서 fastEthenet


central(config-if)#description R1_connect


central(config)#interface fa
central(config)#interface fastEthernet 0/0
central(config-if)#no shutdown
central(config-if)#ip address 172.16.1.65 255.255.255.224
central(config)#int s0/0
central(config-if)#ip address 172.16.1.161 255.255.255.224

central(config-if)#clock rate 64000


Router passwd 설정


R1#configure t
R1(config)#enable password cisco

Router>en 명령시 password 물어봄


R1#configure t
R1(config)#enable secret aaa


enable password 와 enable secret 가 되어 있다고 하면

enable secret 우선 순위가 높다

R1#show running-config

enable secret 5 $1$mERr$0qc4f9z9UYCi6V2sVqpTi.
enable password cisco


secret 는 암호화 되어 저장된다.
password 는 암호화 안되어서 저장이 된다.


R1#conf t
R1(config-line)#password bbb

Router 접속시 무조건 암호를 물어 본다.


--------------------
Router telnet 구성

R1#configure t
Enter configuration commands, one per line.  End with CNTL/Z.
R1(config)#line vty 0 4 // 5명의 접속자


R1(config-line)#password abcd

R1(config)#ip route 172.16.1.64 255.255.255.224 s 0/0 // 172.16.1.64 net ID


Router R1 Setting

R1#configure t
Enter configuration commands, one per line.  End with CNTL/Z.
R1(config)#ip rou
R1(config)#ip route 172.16.1.96 255.255.255.224 s             // 172.16.1.96 netID
R1(config)#ip route 172.16.1.96 255.255.255.224 serial 0/0
R1(config)#ip route 172.16.1.64 255.255.255.224 serial 0/0

다른 대역의 NETID 를 집어 넣으면 된다. 다른 장비와 연결된 시리얼 넘버를 지정해 주면 된다.

 

Router R2 Setting

R2>en
R2#confi
R2#configure t
R2#configure terminal
Enter configuration commands, one per line.  End with CNTL/Z.
R3(config)#
R2(config)#ip route 172.16.1.32 255.255.255.224 serial 0/1
R2(config)#ip route 172.16.1.96 255.255.255.224 serial 0/0


Router R3 Setting

R3>en
R3#confi
R3#configure t
R3#configure terminal
Enter configuration commands, one per line.  End with CNTL/Z.
R3(config)#
R3(config)#ip route 172.16.1.64 255.255.255.224 serial 0/1
R3(config)#ip route 172.16.1.32 255.255.255.224 serial 0/1