ciscoルータ設定

コンソール接続

http://www.infraexpert.com/study/ciscoios.html

出荷時に戻す

下記コマンドを実行し、startup-configを削除すればOK
# erase startup-config

PPPOEセッション設定

環境

  • フレッツ光 (個人用)
  • ルータ:cisco1812J
  • LAN
    • Fa0とプロバイダをPPPoEで接続する
    • 固定IP
    • プロバイダID:xxx@xxx.com
    • プロバイダpass:xxx
    • MTU:1454 (ntt)
    • MSS:1414
    • LAN内のPCに対してDHCPでIPアドレスを払い出す
      • ネットワーク : 192.168.1.0/24
      • デフォルトゲートウェイ: 192.168.1.1
      • DNS : 192.168.1.1
    • ルータがDNSフォワーディングを行う。

VLANの設定

xxx>enable
Password:
xxx#
 
xxx#show vlan-switch
Load for five secs: 0%/0%; one minute: 0%; five minutes: 1%
Time source is hardware calendar, *22:12:59.855 JST Sun May 5 2013
 
VLAN Name                             Status    Ports
---- -------------------------------- --------- -------------------------------
1    default                          active    Fa2, Fa3, Fa4, Fa5, Fa6, Fa7
                                                Fa8, Fa9
1002 fddi-default                     active
1003 token-ring-default               active
1004 fddinet-default                  active
1005 trnet-default                    active
 
VLAN Type  SAID       MTU   Parent RingNo BridgeNo Stp  BrdgMode Trans1 Trans2
---- ----- ---------- ----- ------ ------ -------- ---- -------- ------ ------
1    enet  100001     1500  -      -      -        -    -        1002   1003
1002 fddi  101002     1500  -      -      -        -    -        1      1003
1003 tr    101003     1500  1005   0      -        -    srb      1      1002
1004 fdnet 101004     1500  -      -      1        ibm  -        0      0
1005 trnet 101005     1500  -      -      1        ibm  -        0      0
Fa2~9はデフォルトでVLAN1に紐づいていました。
xxx# configure terminal
 
xxx(config)#interface vlan1
xxx(config-if)#ip addr 192.168.1.1 255.255.255.0
xxx(config-if)#ip tcp adjust-mss 1414
xxx(config-if)#ip ip nat inside
xxx(config-if)#no shutdown
xxx(config-if)#exit

Loopback

xxx(config)#interface Loopback0
xxx(config-if)#ip address xxx.xxx.xxx.xxx 255.255.255.255
xxx(config-if)#no shutdown

DHCPの設定

xxx(config)#ip dhcp excluded-address 192.168.1.1
xxx(config)#ip dhcp pool LAN
xxx(dhcp-config)#network 192.168.1.0 255.255.255.0
xxx(dhcp-config)#dns-server 192.168.1.1
xxx(dhcp-config)#default-router 192.168.1.1
xxx(dhcp-config)#exit

PPPoEの設定

xxx(config)#interface di0
xxx(config-if)#ip address negotiated
xxx(config-if)#ip unnumbered Loopback0
xxx(config-if)#ip mtu 1454
xxx(config-if)#ip nat outside
xxx(config-if)#encapsulation ppp
xxx(config-if)#dialer pool 1
xxx(config-if)#dialer-group 1
xxx(config-if)#ppp authentication chap callin
xxx(config-if)#ppp chap hostname xxx@xxx.com
xxx(config-if)#ppp chap password xxx
xxx(config-if)#ppp ipcp dns request accept
xxx(config-if)#no shutdown
xxx(config-if)#exit
 
xxx(config)#ip route 0.0.0.0 0.0.0.0 di0
xxx(config)#dialer-list 1 protocol ip permit
 
xxx(config)#interface fa0
xxx(config-if)#no ip address
xxx(config-if)#pppoe enable group global
xxx(config-if)#pppoe-client dial-pool-number 1
xxx(config-if)#no shutdown
xxx(config-if)#exit
 
xxx(config)#access-list 1 permit 192.168.1.0 0.0.0.255
xxx(config)#ip nat inside source list 1 interface Loopback0
xxx(config)#ip dns server
xxx(config)#ip host xxx 192.168.1.1
 
xxx(config)#interface fa2
xxx(config-if)#no shutdown
xxx(config-if)#exit

参考

このブログの人気の投稿

RAC環境でimpdpをパラレルで実行するとき

ctrl+s 操作が不能に

TrustedInstaller.exe メモリリーク