PDA

View Full Version : Qui trình khôi phục password trên Cisco router.



dangquangminh
26-12-2003, 08:53 AM
Qui trình khôi phục password (password recovery)

I. Đối với Cisco 1600, 1700 and 2600 Series Routers:

1. Vào HyperTerminal (Private Edition 5.0 or higher) console.

2. Tắt router, sau đó bật lại. Nhấn Ctrl-Break trong vòng 60 giây

monitor: command "boot" aborted due to user interrupt
rommon 1 >

3. Dùng lệnh confreg để đổi nội dung thanh ghi sang 2142.

rommon 1 >confreg 0x2142

4. Reboot the router with the reset command.

rommon 2 >reset

5. Sau khi reboot, dùng Ctrl-C để vào user mode:

router>

6.

router>enable
router#copy startup-config running-config

7.

router>enable
router#show startup-config

8. Đặt lại password mới:

router#config term
router(config)#enable secret newpassword
router(config)#enable password newpassword
router(config)#line con 0
router(config-line)#login
router(config-line)#password newpassword
router(config)#line aux 0
router(config-line)#login
router(config-line)#password newpassword
router(config)#line vty 0 4
router(config-line)#login
router(config-line)#password newpassword

9. #copy run start

10. Khôi phục giá trị thanh ghi về 0x2102

router#config term
router(config)#config-register 0x2102
router(config)#exit
router#copy running-config startup-config

11. Kiểm tra nội dung thanh ghi

router#show version
Cisco Internetwork Operating System Software
IOS (tm) C2600 Software (C2600-DO3S-M), Version 12.0(5)T1, RELEASE
SOFTWARE (fc1)
Copyright (c) 1986-1999 by cisco Systems, Inc.
Compiled Tue 17-Aug-99 13:18 by cmong
Image text-base: 0x80008088, data-base: 0x80CB67B0
ROM: System Bootstrap, Version 11.3(2)XA4, RELEASE SOFTWARE (fc1)
1 FastEthernet/IEEE 802.3 interface(s)
2 Low-speed serial(sync/async) network interface(s)
32K bytes of non-volatile configuration memory.
8192K bytes of processor board System flash (Read/Write)

Configuration register is 0x2142 (will be 0x2102 at next reload)


II. Cisco 2500 Series Routers:

1. Thiết lập HyperTerminal (Private Edition 5.0 or higher) console .

2. Tắt routers, sau đó bật lại. Nhấn CTRL-BREAK trong vòng 60 giây.

Abort at 0x10EA884 (PC)
>

3. Đổi nội dung thanh ghi thành 0x2142

>o/r 0x2142 (lower case of the letter O for o/r and zero for 0x2142)

4. Reboot router

>i

5. Nhấn Ctrl-C để vào user mode khi router khởi động lại

router>

6. Vào enable mode

router>enable
router#copy startup-config running-config
7. Thực hiện các lệnh show running-config or show startup-config
router#show startup-config

8.

router#config term
router(config)#enable secret newpassword
router(config)#enable password newpassword
router(config)#line con 0
router(config-line)#login
router(config-line)#password newpassword
router(config)#line aux 0
router(config-line)#login
router(config-line)#password newpassword
router(config)#line vty 0 4
router(config-line)#login
router(config-line)#password newpassword

9. Copying the startup-configuration to running-configuration. Thực hiện lệnh no shutdown trên tất cả các interface được dùng.

10. Chuyển nội dung thanh ghi về giá trị ban đầu. Lưu cấu hình

router#config term
router(config)#config-register 0x2102
router#copy running-config startup-config

11. Kiểm tra thanh ghi có giá trị là 2102 bằng lệnh show version

router#show version
Cisco Internetwork Operating System Software
IOS (tm) 2500 Software (C2500-D-L), Version 12.0(4), RELEASE SOFTWARE
(fc1)
Copyright (c) 1986-1999 by cisco Systems, Inc.
ROM: System Bootstrap, Version 5.2(8a), RELEASE SOFTWARE
BOOTFLASH: 3000 Bootstrap Software (IGS-RXBOOT), Version 10.2(8a), RELEASE
SOFTWARE (fc1)
1 Ethernet/IEEE 802.3 interface(s)
2 Serial network interface(s)
1 ISDN Basic Rate interface(s)
32K bytes of non-volatile configuration memory.
8192K bytes of processor board System flash (Read ONLY)
Configuration register is 0x2142 (will be 0x2102 at next reload)

12. Reboot the router.
router#reload

Chúc thành công,

leminhkhoi
06-01-2004, 04:13 PM
Bạn khôn cần nhấn ctrl+break trong vòng 60 giây đâu, chỉ cần 5s là được rồi
Thân chào

Saigon,Vietnam
10-01-2004, 11:58 AM
Chào tất cả,

Lê Minh-Khôi viết:
"Bạn khôn cần nhấn ctrl+break trong vòng 60 giây đâu, chỉ cần 5s là được rồi "

Vậy mình biết nghe ai, anh Minh hay Khôi?
Mình có kinh-nghiệm sau:

1. Vào HyperTerminal (Private Edition 5.0 or higher) console.
2. Tắt router, sau đó bật lại. Nhấn Ctrl-Break trong vòng (?) giây.

Thực ra thời gian này dài hay ngắn là tuỳ theo models, Dram, và IOS image size. Cụ thể nhất, bạn sẽ break boot sequence sau khi DRAM checked. Dó là ngay sau khi bạn thấy message tương tự sau dây hiện lên:

"Copyright (c) 1998 by cisco Systems, Inc.
C3600 processor with 131072 Kbytes of main memory
Main memory is configured to 64 bit mode with parity disabled"

Các bạn cũng không muốn break boot sequence sau khi full IOS image has been searched. Khi dó bạn sẽ thấy message sau xuất hiện:

"program load complete, entry point: 0x80008000, size: 0xe97f54
Self decompressing the image : ################################################## ################################################## ################################################## ########### [OK]"

Lúc message tương tự dã xuất hiện, bạn không còn break dược nữa.

Tóm lại, "nhấn ctrl+break trong vòng bao lâu?" là tuỳ vào router/switch thôi các bạn ạ! Cisco nói 60 seconds là chung-chung thôi! Với một Cisco router nào dó bạn cũng verify dễ dàng.

Thân,

tvtphys
12-01-2004, 10:11 AM
xin cho hỏi tôi đặt lại password
router 2501 báo như sau: khi config xong gõ lại pass thì báo sai(đã kiểm tra nhiều lần pass) có phải vì lý do dưới mà báo sai?

The enable secret you have chosen is the same as your enable password.
This is not recommended. Re-enter the enable secret
xin cảm ơn

tvtphys
12-01-2004, 10:35 AM
xin cho hỏi tôi đặt lại password
router 2501 báo như sau: khi config xong gõ lại pass thì báo sai(đã kiểm tra nhiều lần pass) có phải vì lý do dưới mà báo sai?

The enable secret you have chosen is the same as your enable password.
This is not recommended. Re-enter the enable secret
xin cảm ơn

3548
13-01-2004, 02:34 PM
Xin chào các bạn,
Các bạn có thể tham khảo file đính kèm.
Chúc vui!

chipchipzzz
13-01-2004, 03:54 PM
tvtphys,
Thông báo trên nói là bạn đặt password "enable secret" (password mã hóa, không hiện ra khi show config) trùng với "password enable" (password ko mã hóa, hiện ra khi show config)

bạn nên đặt 2 password này bằng 2 chuỗi khác nhau

chúc vui,

leminhkhoi
01-02-2004, 11:52 AM
enable pass có hai loại một loại không mã hoá(show run sẽ thấy) và loại mã hoá . Khi bạn đặt enable secret trùng với enable password thì sẽ không được.
Khi enable secret khác với enable password thì enable secret được dùng khi bạn gõ lệnh enable .
thân chào

linhduongc18
19-01-2010, 02:47 PM
the cac bac oi khoi phuc cisco 1841 thi lam nhu the nao?xin cac bac chi dum e voi

phuongpheoo
19-01-2010, 04:37 PM
1800,2800,3800 series cũng như 1600,1700,2600 thôi bạn à :D. Bạn không cần máy móc, tự mày mò 1 tý bạn sẽ thấy quy trình trên chẳng qua là các bước: vào rommon, thay đổi giá trị thanh ghi sao cho startup config không load khi boot, boot tiếp tục , thế là xong, đơn giản thế và có thể áp dụng cho hầu hết các network hardware, nhất là cisco, các thiết bị khác thì hơi khác một chút nhưng ý tưởng vẫn là vậy. Chịu khó tìm tòi sẽ rất vui và nhanh tiến bộ. Chúc bạn thành công nhé. Thân :D.