🐥
Cisco機器のログの見方
最近Cisco機器に触れる中で、ログの見方に困る場面が多かったため、まとめてみました。
今回紹介するコマンド
-
show running-config
(現在の設定を見る) -
show ip route
(ルーティングの情報を見る) -
show interfaces
(ポートの状態を見る)
show running-config
:現在の設定を確認する
1. ネットワーク機器が今どんな設定で動いているかを確認できるコマンドです。
🔧実際の出力例(スイッチ)
Switch# show running-config
Building configuration...
Current configuration : 1428 bytes
!
version 15.2
hostname Switch
!
interface FastEthernet0/1
switchport access vlan 10
switchport mode access
!
interface FastEthernet0/2
switchport access vlan 20
switchport mode access
!
interface Vlan1
ip address 192.168.1.1 255.255.255.0
no shutdown
!
line vty 0 4
password cisco
login
!
end
各種項目説明
hostname Switch
この機器の名前です。
interface FastEthernet0/1
switchport access vlan 10
switchport mode access
-
interface FastEthernet0/1
:ポート名です。 -
switchport access vlan 10
:このポートがVLAN 10に属しています。 -
switchport mode access
:このポートがアクセスポートとして利用されています。
interface Vlan1
ip address 192.168.1.1 255.255.255.0
no shutdown
-
interface Vlan1
: VLAN 1 -
ip address
: スイッチ自体に設定されたIPアドレス(telnetなど)です。 -
no shutdown
: このインターフェースが有効化されている状態を表しています。
line vty 0 4
password cisco
login
- リモートログイン(telnet)用の設定です。
-
password cisco
: [cisco]というパスワードが設定されています。 -
login
: パスワードを入力しないと接続できないようにする設定です。
Discussion