ルータ設定方法(基本編)

Index


Cisco800ルータに接続する方法

Cisco 800 ルータとハード的な接続を行う

  1. ハイパーターミナル起動

  2. 設定
    ビット数/秒 9600
    データビット 8
    パリティ なし
    ストップビット 1
    フロー制御 なし

基本設定

最初にルータに接続すると下記の画面が表示されます
( ) は入力項目

  1. Would you like to enter the initial configuration dialog? [yes/no] (yes enter)

  2. Would you like to enter basic management setup? [yes/no] (yes enter)

  3. Enter host name [Router] : (router1) ルータの名前を決めます

  4. Enter enable secret : (secret) 

  5. Enter enable password : (secret)
    注) 特権モードに入るためのパスワード。Enable secret が設定されていれば、特権モードに入るのに、Enable password は利用されない。

  6. The virtual terminal password is used to protect access to the router over a network interface。Enter virtual terminal password : secret

  7. Configure SNMP Network Management ? [yes] : (no)

  8. Enter interface name used to connect to the management network from the above interface : Ethernet0

  9. configure interface Ethernet 0 : configure IP on this interface? [yes] : (yes)

  10. IP address for this Interface : 192.168.2.200 Ethernet 側のIPアドレスを決めます

  11. Subnet mask for this interface : 255.255.255.0

  12. [0] Go to the IOS command prompt without saving this config.
    [1] Return back to the setup without saving this config
    [2] Save this configuration to nvram and exit
    (Enter)

WANインターフェースの設定

概説
・ ラインの反対側にデバイスが1つだけあるという状態なので、ポイントツーポイントではパケットの送り先となるアドレスあるいはマシンを指定する必要が無い。そのため特にIPアドレスを振る必要は無い(これはunnumbered 番号無し インターフェース)。Unnumbered インタフェースを使うときには、WANリンクの両端がunnumbered インタフェースになっている必要がある。
・ IPアドレスをあえて使いたい場合は、IPアドレスコマンドを使う。

  1. router1>enable

  2. password : secret

  3. router1#configure

  4. router1(config)#interface bri 0

  5. router1(config-if)#ip address 192.168.3.1 255.255.255.0 BRIインタフェースにIPアドレスを入力

  6. router1 (config-if)#encapsulation ppp BRI インタフェースがどのようなカプセル化を使うか指定

  7. router1 (config-if)#isdn switch-type ntt 日本のISDN回線であれば、nttを選択します

  8. router1 (config) dialer-list 1 protocol ip permit IPプロトコルによってダイヤルする事を許可します

  9. router1 (config-if) # dialer-group 1 

  10. router1 (config-if) #dialer string 02 電話番号

  11. router1(config-if) # no shut BRIインタフェースが動作するようにします(デフォルトでは動いていません)

ISDNインタフェースへのアドレス指定
デバイスが別のデバイスへのコールを確立したいときに有効になる。デバイスが通信呼を受け取る(インバウンドコール)だけであれば、IPアドレスを相手のデバイスと電話番号にダイナミックに関連付けるようにできる。
Cisco IOS のインタフェース設定サブコマンドdialer mapを使って、システム名およびISDNを経由して呼をセットアップする多面ビ使われた電話番号とIP アドレスとの関連付けを提供しています。Dialer map コマンドにはnameというキーワードがあって、リモートシステムの電話番号とIPアドレスとを正しく関連付けるのに必要になります。さらにnameキーワードは、リモートシステムとの接続が確立されるときの認証プロセスの一部としても使われます。

IPルーティングの設定

  1. router1 (config) ip route 192.168.1.0 255.255.255.0 192.168.3.10

  2. router1 (config) ip route 192.168.3.10 255.255.255.255 bri0

  3. router1 (config) ip routing IPルーティングを有効にします

構成の保存

router1# write memory NVRAM に書込み、構成を保存します

もう一方のルータで設定する。

Router1の構成情報
Show run の結果

router1#sh run
Building configuration...

Current configuration:
!
version 12.0
no service pad
service timestamps debug uptime
service timestamps log uptime
no service password-encryption
!
hostname router1
!
enable secret 5 $1$PrhY$IstPAooHrfpw6ZrWDS0s3/
enable password secret
!
!
!
!
!
ip subnet-zero
!
isdn switch-type ntt
isdn voice-call-failure 0
!
!
!
interface Ethernet0
    ip address 192.168.2.200 255.255.255.0
    no ip directed-broadcast
!
interface BRI0
    ip address 192.168.3.1 255.255.255.0
    no ip directed-broadcast
    encapsulation ppp
    dialer string 02
    dialer-group 1
    isdn switch-type ntt
!
no ip http server
ip classless
ip route 192.168.1.0 255.255.255.0 192.168.3.10
ip route 192.168.3.10 255.255.255.255 BRI0
!
dialer-list 1 protocol ip permit
!
line con 0
    transport input none
    stopbits 1
line vty 0 4
    password secret
    login
!
end

show interface の結果

router1#sh int
BRI0 is up, line protocol is up (spoofing)
    Hardware is BRI with S/T interface
    Internet address is 192.168.3.1/24
    MTU 1500 bytes, BW 64 Kbit, DLY 20000 usec,
        reliability 255/255, txload 1/255, rxload 1/255
    Encapsulation PPP, loopback not set
    Last input 00:00:05, output 00:00:05, output hang never
    Last clearing of "show interface" counters 00:55:25
    Input queue: 0/75/0 (size/max/drops); Total output drops: 0
    Queueing strategy: weighted fair
    Output queue: 0/1000/64/0 (size/max total/threshold/drops)
        Conversations 0/1/16 (active/max active/max total)
        Reserved Conversations 0/0 (allocated/max allocated)
    5 minute input rate 0 bits/sec, 0 packets/sec
    5 minute output rate 0 bits/sec, 0 packets/sec
        340 packets input, 1409 bytes, 0 no buffer
        Received 0 broadcasts, 0 runts, 0 giants, 0 throttles
        0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored, 0 abort
        340 packets output, 1435 bytes, 0 underruns
        0 output errors, 0 collisions, 1 interface resets
        0 output buffer failures, 0 output buffers swapped out
        1 carrier transitions
BRI0:1 is down, line protocol is down
    Hardware is BRI with S/T interface
    MTU 1500 bytes, BW 64 Kbit, DLY 20000 usec,
        reliability 255/255, txload 1/255, rxload 1/255
    Encapsulation PPP, loopback not set
    Keepalive set (10 sec)
    LCP Closed
    Closed: CDPCP, IPCP
    Last input 00:13:17, output 00:13:17, output hang never
    Last clearing of "show interface" counters never
    Input queue: 0/75/0 (size/max/drops); Total output drops: 0
    Queueing strategy: weighted fair
    Output queue: 0/1000/64/0 (size/max total/threshold/drops)
        Conversations 0/1/16 (active/max active/max total)
        Reserved Conversations 0/0 (allocated/max allocated)
    5 minute input rate 0 bits/sec, 0 packets/sec
    5 minute output rate 0 bits/sec, 0 packets/sec
        82 packets input, 3944 bytes, 0 no buffer
        Received 0 broadcasts, 0 runts, 0 giants, 0 throttles
        0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored, 0 abort
        81 packets output, 3653 bytes, 0 underruns
        0 output errors, 0 collisions, 0 interface resets
        0 output buffer failures, 0 output buffers swapped out
        4 carrier transitions
BRI0:2 is down, line protocol is down
    Hardware is BRI with S/T interface
    MTU 1500 bytes, BW 64 Kbit, DLY 20000 usec,
        reliability 255/255, txload 1/255, rxload 1/255
    Encapsulation PPP, loopback not set
    Keepalive set (10 sec)
    LCP Closed
    Closed: CDPCP, IPCP
    Last input never, output never, output hang never
    Last clearing of "show interface" counters never
    Input queue: 0/75/0 (size/max/drops); Total output drops: 0
    Queueing strategy: weighted fair
    Output queue: 0/1000/64/0 (size/max total/threshold/drops)
        Conversations 0/0/16 (active/max active/max total)
        Reserved Conversations 0/0 (allocated/max allocated)
    5 minute input rate 0 bits/sec, 0 packets/sec
    5 minute output rate 0 bits/sec, 0 packets/sec
        0 packets input, 0 bytes, 0 no buffer
        Received 0 broadcasts, 0 runts, 0 giants, 0 throttles
        0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored, 0 abort
        0 packets output, 0 bytes, 0 underruns
        0 output errors, 0 collisions, 0 interface resets
        0 output buffer failures, 0 output buffers swapped out
        0 carrier transitions
Ethernet0 is up, line protocol is up
    Hardware is PQUICC Ethernet, address is 00b0.c289.955a (bia 00b0.c289.955a)
    Internet address is 192.168.2.200/24
    MTU 1500 bytes, BW 10000 Kbit, DLY 1000 usec,
        reliability 255/255, txload 1/255, rxload 1/255
    Encapsulation ARPA, loopback not set
    Keepalive set (10 sec)
    ARP type: ARPA, ARP Timeout 04:00:00
    Last input 00:00:58, output 00:00:03, output hang never
    Last clearing of "show interface" counters never
    Queueing strategy: fifo
    Output queue 0/40, 0 drops; input queue 0/75, 0 drops
    5 minute input rate 0 bits/sec, 0 packets/sec
    5 minute output rate 0 bits/sec, 0 packets/sec
        2640 packets input, 304914 bytes, 0 no buffer
        Received 2613 broadcasts, 0 runts, 0 giants, 0 throttles
        0 input errors, 0 CRC, 0 frame, 0 overrun, 0 ignored
        0 input packets with dribble condition detected
        1534 packets output, 153432 bytes, 0 underruns
        0 output errors, 0 collisions, 3 interface resets
        0 babbles, 0 late collision, 0 deferred
        0 lost carrier, 0 no carrier
        0 output buffer failures, 0 output buffers swapped out