Cisco IOS でコンフィグを行番号付き表示する

Cisco IOS では show running-config linenum でコンフィグを行番号付きで表示出来ます。

VIRL 1.2.83 上の IOSv での実行例は以下の通りです。

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
Router# show running-config linenum
Building configuration...

Current configuration : 2569 bytes
     1 : !
     2 : version 15.6
     3 : service timestamps debug datetime msec
     4 : service timestamps log datetime msec
     5 : no service password-encryption
     6 : !
     7 : hostname Router
     8 : !
     9 : boot-start-marker
    10 : boot-end-marker
    11 : !
    12 : !
    13 : !
    14 : no aaa new-model
    15 : ethernet lmi ce
    16 : !
    17 : !
    18 : !
    19 : mmi polling-interval 60
    20 : no mmi auto-configure
    21 : no mmi pvc
    22 : mmi snmp-timeout 180
    23 : !
    24 : !
    25 : !
    26 : !
    27 : !
    28 : !
    29 : !
    30 : !
    31 : !
    32 : !
    33 : !
    34 : ip cef
    35 : no ipv6 cef
    36 : !
    37 : multilink bundle-name authenticated
    38 : !
    39 : !
    40 : !
    41 : !
    42 : !
    43 : redundancy
    44 : !
    45 : !
    46 : !
    47 : !
    48 : !
    49 : !
    50 : !
    51 : !
    52 : !
    53 : !
    54 : !
    55 : !
    56 : !
    57 : !
    58 : !
    59 : interface GigabitEthernet0/0
    60 :  no ip address
    61 :  shutdown
    62 :  duplex auto
    63 :  speed auto
    64 :  media-type rj45
    65 : !
    66 : ip forward-protocol nd
    67 : !
    68 : !
    69 : no ip http server
    70 : no ip http secure-server
    71 : !
    72 : !
    73 : !
    74 : !
    75 : control-plane
    76 : !
    77 : banner exec ^C
    78 : **************************************************************************
    79 : * IOSv is strictly limited to use for evaluation, demonstration and IOS  *
    80 : * education. IOSv is provided as-is and is not supported by Cisco's      *
    81 : * Technical Advisory Center. Any use or disclosure, in whole or in part, *
    82 : * of the IOSv Software or Documentation to any third party for any       *
    83 : * purposes is expressly prohibited except as otherwise authorized by     *
    84 : * Cisco in writing.                                                      *
    85 : **************************************************************************^C
    86 : banner incoming ^C
    87 : **************************************************************************
    88 : * IOSv is strictly limited to use for evaluation, demonstration and IOS  *
    89 : * education. IOSv is provided as-is and is not supported by Cisco's      *
    90 : * Technical Advisory Center. Any use or disclosure, in whole or in part, *
    91 : * of the IOSv Software or Documentation to any third party for any       *
    92 : * purposes is expressly prohibited except as otherwise authorized by     *
    93 : * Cisco in writing.                                                      *
    94 : **************************************************************************^C
    95 : banner login ^C
    96 : **************************************************************************
    97 : * IOSv is strictly limited to use for evaluation, demonstration and IOS  *
    98 : * education. IOSv is provided as-is and is not supported by Cisco's      *
    99 : * Technical Advisory Center. Any use or disclosure, in whole or in part, *
   100 : * of the IOSv Software or Documentation to any third party for any       *
   101 : * purposes is expressly prohibited except as otherwise authorized by     *
   102 : * Cisco in writing.                                                      *
   103 : **************************************************************************^C
   104 : !
   105 : line con 0
   106 : line aux 0
   107 : line vty 0 4
   108 :  login
   109 :  transport input none
   110 : !
   111 : no scheduler allocate
   112 : !
   113 : end
Router#