@network Cisco・アライド実機で学ぶ > Cisco実機で学ぶ(CCNA) > ヘルプ機能

 Rakuten
@network Cisco・アライド実機で学ぶ
◆ヘルプ機能

※動作確認は、Cisco2500、Cisco1720、Cisco1721、Cisco2611、Cisco2650、Cisco3620シリーズのルータ、Catalyst2900、Catalyst2950シリーズのスイッチなどで確認しています。コマンド、出力結果、動作は、機種、IOSのバージョンで異なる場合があります。

◆ヘルプ機能

IOSコマンドを全て覚えるのは大変です。

 各コマンドでは、さまざまなオプションが指定可能です。

 コマンドのオプションまで覚えようと思うと気の遠い話になってしまいます。

 しかし、Cisco IOSでは、ヘルプ機能が充実しています。コマンド入力を支援する機能が以下のように用意されています。

・コマンドの一覧
・オプションの確認
・補完機能

このヘルプ機能を使うには、分からないところで、「?」を入力します。

まず、特権モードでどんなコマンドが入力できるのか確認してみましょう!

●特権モードで入力できるコマンドの確認
Router#?
Exec commands:
  access-enable    Create a temporary Access-List entry
  access-profile   Apply user-profile to interface
  access-template  Create a temporary Access-List entry
  bfe              For manual emergency modes setting
  cd               Change current directory
  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
  help             Description of the interactive help system
  lock             Lock the terminal
  login            Log in as a particular user
  logout           Exit from the EXEC
  more             Display the contents of a file
  mrinfo           Request neighbor and version information from a multicast
                   router
  mstat            Show statistics after multiple multicast traceroutes
  mtrace           Trace reverse multicast path from destination to source
  name-connection  Name an existing network connection
  no               Disable debugging functions
  pad              Open a X.29 PAD connection
  ping             Send echo messages
  ppp              Start IETF Point-to-Point Protocol (PPP)
  pwd              Display current working directory
  reload           Halt and perform a cold restart
  resume           Resume an active network connection
  rlogin           Open an rlogin connection
  rsh              Execute a remote command
  send             Send a message to other tty lines
  set              Set system parameter (not config)
  setup            Run the SETUP command facility
  show             Show running system information
  slip             Start Serial-line IP (SLIP)
  start-chat       Start a chat-script on a line
  systat           Display information about terminal lines
  telnet           Open a telnet connection
  terminal         Set terminal line parameters
  test             Test subsystems, memory, and interfaces
  traceroute       Trace route to destination
  tunnel           Open a tunnel connection
  undebug          Disable debugging functions (see also 'debug')
  verify           Verify a file
  where            List active connections
  write            Write running configuration to memory, network, or terminal
  x28              Become an X.28 PAD
  x3               Set X.3 parameters on PAD

特権モードで入力できるコマンドが確認できます。

例えば、コマンドをうる覚えしていて、「s」で始まるコマンドであるとしか思い出せなかったとします。

そこで、

Router#s?

●「s」で始まるコマンドを表示
Router#s?
*s=show  send        set     setup  show
slip     start-chat  systat

「s」で始まるコマンドが表示できます。この中から、探せばいいのです。大抵は、ここまで表示されれば思い出せるはずです。

次に、オプションを思い出せなかったとします。

Router#show ?

 「 ?」(スペース+?)とコマンドの続きに入力することで、次のオプション

●オプションの確認
Router#show ?
  access-expression  List access expression
  access-lists       List access lists
  accounting         Accounting data for active sessions
  adjacency          Adjacent nodes
  aliases            Display alias commands
  arp                ARP table
  async              Information on terminal lines used as router interfaces
  backup             Backup status
  bridge             Bridge Forwarding/Filtering Database [verbose]
  buffers            Buffer pool statistics
  c2600              Show c2600 information
  cdp                CDP information
  cef                Cisco Express Forwarding
  clock              Display the system clock
  compress           Show compression statistics
  configuration      Contents of Non-Volatile memory
  context            Show context information
  controllers        Interface controller status
  debugging          State of each debugging option
  dhcp               Dynamic Host Configuration Protocol status
  diag               Show diagnostic information for port adapters/modules
  dialer             Dialer parameters and statistics
  dnsix              Shows Dnsix/DMDP information
  dxi                atm-dxi information
  entry              Queued terminal entries
  environment        Environmental monitor statistics
  file               Show filesystem information
  flash:             display information about flash: file system
  frame-relay        Frame-Relay information
  history            Display the session command history
  hosts              IP domain-name, lookup style, nameservers, and host table
  interfaces         Interface status and configuration
  ip                 IP information
  key                Key information
  line               TTY line information
  llc2               IBM LLC2 circuit information
  location           Display the system location
  logging            Show the contents of logging buffers
  memory             Memory statistics
  modemcap           Show Modem Capabilities database
  ntp                Network time protocol
  pas                Port Adaptor Information
  pci                PCI Information
  ppp                PPP parameters and statistics
  printers           Show LPD printer information
  privilege          Show current privilege level
  processes          Active process statistics
  protocols          Active network routing protocols
  queue              Show queue contents
  queueing           Show queueing configuration
  registry           Function registry information
  reload             Scheduled reload information
  rhosts             Remote-host+user equivalences
  rif                RIF cache entries
  rmon               rmon statistics
  route-map          route-map information
  rtr                Response Time Reporter (RTR)
  running-config     Current operating configuration
  sessions           Information about Telnet connections
  smf                Software MAC filter
  snapshot           Snapshot parameters and statistics
  snmp               snmp statistics
  spanning-tree      Spanning tree topology
  stacks             Process stack utilization
  standby            Hot standby protocol information
  startup-config     Contents of startup configuration
  subscriber-policy  Subscriber policy
  subsys             Show subsystem information
  tacacs             Shows tacacs+ server statistics
  tcp                Status of TCP connections
  tech-support       Show system information for Tech-Support
  terminal           Display terminal configuration parameters
  traffic-shape      traffic rate shaping configuration
  users              Display information about terminal lines
  version            System hardware and software status
  whoami             Info on current tty line
  x25                X.25 information
  x29                X.29 information

これだと、候補が多すぎて迷うかもしれません。覚えているところまで、入力すれば、候補を絞ることができます。

例えば、

Router#show c?

と入力すると、「show」コマンドで「c」で始まるオプションを表示してくれます。

●「show」コマンドで「c」で始まるオプション
Router#show c?
c2600          cdp      cef          clock  compress
configuration  context  controllers

●補完機能

 コマンドの入力に慣れてくるとコマンドを最後まで入力するのが面倒になってきます。IOSコマンドでは、コマンドやオプションが、入力場所で一意になる長さまで入力すればコマンドが補完されるようになっています。省略コマンドを入力しても、「show running-config」で確認するとちゃんとコマンドがフルスペルで設定されていることが確認できます。

 また、入力時に「TAB」キーを押すことでも入力最中にコマンドやオプションの補完ができます。これは、スペルミス防止にとても役立ちます。

例えば、

show controllersと入力する時に、

Router#show contr[TAB]と押せば

Router#show contr[TAB]
Router#show controllers

show controllersと補完されます。

show cont[TAB]と入力してみて下さい。

Router#show cont[TAB]
Router#show cont

show contのままだと思います。

 それは、「show」コマンドのオプションで指定できるコマンドには、「cont」で始まるオプションが2つあるからです。2つ以上候補がある場合は、「TAB」で補完できません。一意(唯一)になるまでの長さを入力しなければなりません。

context
controllers

ヘルプ機能を利用すれば、どんなにオプション指定が多くて長いコマンドでも最後まで入力できると思います。

スポンサードリンク


<ネットワーク資格の練習問題に挑戦>
CCNA練習問題に挑戦!(650問)
Network+練習問題に挑戦!(393問)
テクニカルエンジニア(ネットワーク)試験
◆Cisco実機で学ぶ(CCNAルータ編)

ルータの概要・基本操作・設定1 (17項目)
ルータの概要・基本操作・設定3 (22項目)
IGRP・EIGRPの設定 (18項目)
アクセスリスト・ACLの設定 (14項目)
NAT・DHCPの設定 (8項目)
ルータの概要・基本操作・設定2 (17項目)
RIPv1・RIPv2の設定 (14項目)
OSPFの設定・デフォルトルートの伝播(16項目)
WANの設定 (10項目)
◆Cisco実機で学ぶ(CCNAスイッチ編)

スイッチの基本操作・設定 (14項目)
VTP・スパニングツリーの設定 (12項目)
MACアドレスの管理・VLANの設定 (12項目)

◆アライドテレシス実機で学ぶ

基本操作・設定 (11項目)
OSPFの設定 (9項目)
ポリシールーティング・VRRPなど (12項目)
VLAN・マルチホーミング・RIPの設定 (10項目)
STP・ポートトランキングなど (14項目)
<関連メニュー>
CCNA実機で学ぶ
CCNP実機で学ぶ
アライドテレシス実機で学ぶ
TCP/IP入門・無料ネットワークツール

Copyright(c)2006- @network Cisco・アライド実機で学ぶ All rights reserved.