PDA

View Full Version : Một Lệnh Hữu Ích Trong IOS Version 12.2(5)T



leminhkhoi
10-12-2003, 02:32 PM
chào các bạn ,
Lâu nay khi các bạn đang ở trong configure mode hay interface mode thì ta không thể thực hiện các lệnh của privilege mode.
Nhưng với lệnh "Do" thì bạn có thể thực hiệc được các lệnh của privilege mode trong mode interface.
ví dụ:


Router#show ver
Cisco Internetwork Operating System Software
IOS (tm) C2600 Software (C2600-I-M), Version 12.2(15)T1, RELEASE SOFTWARE (fc1)
TAC Support: http://www.cisco.com/tac
Copyright (c) 1986-2003 by cisco Systems, Inc.
Compiled Thu 27-Mar-03 16:44 by ccai
Image text-base: 0x80008098, data-base: 0x80C224CC

ROM: System Bootstrap, Version 12.2(7r) [cmong 7r], RELEASE SOFTWARE (fc1)

Router uptime is 3 hours, 21 minutes
System returned to ROM by power-on
System image file is "flash:c2600-i-mz.122-15.T1.bin"

cisco 2620XM (MPC860P) processor (revision 0x100) with 28672K/4096K bytes of memory.
Processor board ID JAD07080Z2A (1366552103)
M860 processor: part number 5, mask 2
Bridging software.
X.25 software, Version 3.0.0.
1 FastEthernet/IEEE 802.3 interface(s)
2 Low-speed serial(sync/async) network interface(s)
32K bytes of non-volatile configuration memory.
16384K bytes of processor board System flash (Read/Write)

Configuration register is 0x2102

Router#conf t
Enter configuration commands, one per line. End with CNTL/Z.
Router(config)#int fas
Router(config)#int fastEthernet 0/0
Router(config-if)#do show run
Building configuration...

Current configuration : 475 bytes
!
version 12.2
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname Router
!
logging queue-limit 100
!
ip subnet-zero
!
!
!
!
!
!
!
interface FastEthernet0/0
no ip address
shutdown
duplex auto
speed auto
!
interface Serial0/0
ip address 10.1.25.2 255.255.255.252
!
interface Serial0/1
ip address 10.1.45.2 255.255.255.252
!
ip http server
ip classless
!
!
!
!
line con 0
line aux 0
line vty 0 4
!
!
end

Router(config-if)#do show int s0/0
Serial0/0 is up, line protocol is up
Hardware is PowerQUICC Serial
Internet address is 10.1.25.2/30
MTU 1500 bytes, BW 128 Kbit, DLY 20000 usec,
reliability 255/255, txload 1/255, rxload 1/255
Encapsulation HDLC, loopback not set
Keepalive set (10 sec)
Last input 00:00:07, output 00:00:03, output hang never
Last clearing of "show interface" counters never
Input queue: 0/75/0/0 (size/max/drops/flushes); Total output drops: 0
Queueing strategy: weighted fair
Output queue: 0/1000/64/0 (size/max total/threshold/drops)
Conversations 0/1/32 (active/max active/max total)
Reserved Conversations 0/0 (allocated/max allocated)
Available Bandwidth 96 kilobits/sec
5 minute input rate 0 bits/sec, 0 packets/sec
5 minute output rate 0 bits/sec, 0 packets/sec
1422 packets input, 97988 bytes, 0 no buffer
Received 1422 broadcasts, 0 runts, 0 giants, 0 throttles
1 input errors, 0 CRC, 1 frame, 0 overrun, 0 ignored, 0 abort
2626 packets output, 170910 bytes, 0 underruns
0 output errors, 0 collisions, 1 interface resets
0 output buffer failures, 0 output buffers swapped out
0 carrier transitions
DCD=up DSR=up DTR=up RTS=up CTS=up

Router(config-if)#
Thân chào

leminhkhoi
10-12-2003, 02:41 PM
Thêm nhé
Nếu các bạn muốn khi show running-config có thêm số dòng thì bạn có thể sử dụng lệnh sau (chú ý là IOS 12.2(4)):

Router#show run linenum
Building configuration...

Current configuration : 475 bytes
1 : !
2 : version 12.2
3 : service timestamps debug datetime msec
4 : service timestamps log datetime msec
5 : no service password-encryption
6 : !
7 : hostname Router
8 : !
9 : logging queue-limit 100
10 : !
11 : ip subnet-zero
12 : !
13 : !
14 : !
15 : !
16 : !
17 : !
18 : !
19 : interface FastEthernet0/0
20 : no ip address
21 : shutdown
22 : duplex auto
23 : speed auto
24 : !
25 : interface Serial0/0
26 : ip address 10.1.25.2 255.255.255.252
27 : !
28 : interface Serial0/1
29 : ip address 10.1.45.2 255.255.255.252
30 : !
31 : ip http server
32 : ip classless
33 : !
34 : !
35 : !
36 : !
37 : line con 0
38 : line aux 0
39 : line vty 0 4
40 : !
41 : !
42 : end

Router#

Neo
10-12-2003, 03:55 PM
Cảm ơn,
Các lệnh này rất hữu ích!

Một số lệnh CLI hidden command mọi người có thể xem thêm ở đây:
http://www.vnpro.org/forum/viewtopic.php?t=641

chipchipzzz
10-12-2003, 05:41 PM
thật tuyệt!

cám ơn Khôi & Neo nhé

it_email
10-12-2003, 08:37 PM
Vậy các version trước ko có những lệnh này sao?
còn lệnh nào khác ko?

leminhkhoi
11-12-2003, 08:41 AM
Đúng là các version trước không hỗ trợ, có lẽ còn nhiều cái mới, nhưng mình chưa tìm ra. Sẽ bổ sung thêm khi nào tìm thêm được các lệnh mới.
Thân chào

ducnguyendinh
28-01-2004, 05:51 PM
Bạn nào co IOS ở trên có thể cho mình xin được không.
Cảm ơn rất nhiều

admin
29-01-2004, 08:07 AM
Hi Đức,

Các IOS của Cisco routers là phụ thuộc vào từng model. Bạn đang cần IOS cho router nào?

Thân mến,

ducnguyendinh
02-02-2004, 02:07 PM
Chào Admin
Tôi cần IOS cho 2620 mà hổ trợ vlan routing

admin
02-02-2004, 10:44 PM
Chào,

Để cấu hình trunking, bạn cần phiên bản IP PLUS.

Admin đã upload lên server rất nổi tiếng của bestirboy. Bạn vào thư mục của server trên download nhé.

Thân chúc bạn vui khoẻ và học tốt,

Admin@vnpro.org