HÃY HƯỞNG ỨNG PHONG TRÀO - ĐƯỜNG PHỐ SẠCH ĐẸP - BẰNG HÀNH ĐỘNG THIẾT THỰC CỦA MÌNH - KHÔNG XẢ RÁC! CẢM ƠN!

Backup và restore/update IOS cho router cisco bằng tftp

PC và Router được cấu hình IP sao cho thấy được nhau.

Ở bài viết này tôi demo bằng router cisco 1841

1.BACKUP

Kiểm tra file ios được lưu trong flash:

Router#dir flash:

Directory of flash:/

    1  -rw-    34414284   Sep 4 2013 10:47:36 +00:00  c1841-advsecurityk9-mz.124-24.T3.bin

64012288 bytes total (29597696 bytes free)

Trên PC chạy chương trình tftp, tiến hành copy ios về PC

Router# copy flash: tftp:

Source filename []? c1841-advsecurityk9-mz.124-24.T3.bin

Address or name of remote host []? 172.18.15.25

Destination filename [c1841-advsecurityk9-mz.124-24.T3.bin]? 

!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

34414284 bytes copied in 518.412 secs (66384 bytes/sec)

Thành công

 

2.UPDATE/RESTORE

Kiểm tra file và dung lượng trên flash

Router#dir flash:

    1  -rw-    34414284   Sep 4 2013 10:47:36 +00:00  c1841-advsecurityk9-mz.124-24.T3.bin

64012288 bytes total (29597696 bytes free)

Nếu dung lượng còn đủ cho IOS mới, chúng ta tiến hành update như sau:

Router#copy ftfp:  flash:

Address or name of remote host []? 172.18.15.25

Source filename []?c1841-advsecurityk9-mz.124-18.bin

Destination filename [c1841-advsecurityk9-mz.124-18.bin]?

Accessing tftp://172.18.15.25/c1841-advsecurityk9-mz.124-18.bin...

Loading c1841-advsecurityk9-mz.124-18.bin from 172.18.15.25 (via Tunnel0): !!!!!

!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

[OK - 21195256 bytes] 21195256 bytes copied in 325.460 secs (65124 bytes/sec)

Kiểm tra lại

 

Router#dir flash:

Directory of flash:/

    2  -rw-    21195256  Feb 24 2015 08:54:28 +00:00  c1841-advsecurityk9-mz.124-18.bin

    1  -rw-    34414284   Sep 4 2013 10:47:36 +00:00  c1841-advsecurityk9-mz.124-24.T3.bin

64012288 bytes total (8400896 bytes free)

Bây giờ ở flash tồn tại 2 IOS

Chỉ định IOS được boot

Router(config)#boot system flash c1841-advsecurityk9-mz.124-18.bin  

  Xóa IOS củ

Router# delete  /f  /r  flash: c1841-advsecurityk9-mz.124-24.T3.bin  

  Reload lại router

Router#reload

  Trường hợp file update trùng với file đã lưu trên flash sẽ báo lỗi

%Warning:There is a file already existing with this name

Do you want to over write? [confirm]

Nếu không đủ dung lượng

Accessing tftp://172.18.15.25/c1841-advsecurityk9-mz.124-24.T3-1.bin...

Loading c1841-advsecurityk9-mz.124-24.T3-1.bin from 172.18.15.25 (via Tunnel0):

!

%Error copying tftp://172.18.15.25/c1841-advsecurityk9-mz.124-24.T3-1.bin (Not enough space on device)

 

Tiến hành xóa ios trên flash rồi update lại ios

 

Số người đang online: 14
PHANKHANH.COM
Copyright@2011 phankhanh.com
Email:khanhnguyen81@yahoo.com