24 April, 2013

CCNP T-Shoot Use TFTP and FTP Servers


#Phase 1: Save IOS or Configuration Using TFTP (Tftpd32)

RCS3600#Copy tftp:X.bin flash:X.bin
Remote address: x.x.x.x
RCS3600#copy running-config tftp:run-con.txt
---------------------------------------------------------
#Phase 2: Save IOS or Configuration Using FTP (Core FTP Servrer)

RCS3600#Copy startup-config ftp://<User>:<Pass>@<ftp server IP>/<Name of file>

Example: 1
RCS3600#copy startup-config ftp://admin:cisco1@192.168.2.200/start.cfg
Address or name of remote host [192.168.2.200]? (Enter)
Destination filename [start.cfg]? (Enter)
Writing start.cfg !
1794 bytes copied in 3.348 secs (536 bytes/sec)
---------------------------------------------------------
Example: 2
RCS3600#configure terminal
RCS3600(config)#ip ftp username admin
RCS3600(config)#ip ftp password cisco1
RCS3600(config)#exit
RCS3600#copy startup-config ftp://192.168.2.200/start2.cfg
Address or name of remote host [192.168.2.200]? (Enter)
Destination filename [start2.cfg]? (Enter)
Writing start2.cfg !
1794 bytes copied in 3.348 secs (536 bytes/sec)
---------------------------------------------------------
#Phase 3: Archiving Configurations 

RCS3600#cd flash:
RCS3600#mkdir cfg-backups
RCS3600#configure terminal
RCS3600(config)#archive
RCS3600(config-archive)#path flash:/cfg-backups/$h-config-$t
RCS3600(config-archive)#time-period 60 (Minutes) (1440 = 1 Day)
RCS3600(config-archive)#maximum 10

***Note:
$H = Hostname
$T = Time Stamp
(In This Router Time Must Be Configured)
---------------------------------------------------------
#Phase 4: Replace Configurations

RCS3600#copy running-config ftp:
Address or name of remote host []? 192.168.2.200 (Enter)
Destination filename [rcs3600-confg]? (Enter)
Writing rcs3600-confg !
1792 bytes copied in 2.292 secs (782 bytes/sec)
RCS3600#configure terminal
RCS3600(config)#hostname Otto 
Otto(config)#exit
Otto#configure replace ftp://192.168.2.200/rcs3600-confg.cfg
This will apply all necessary additions and deletions
to replace the current running configuration with the
contents of the specified configuration file, which is
assumed to be a complete configuration, not a partial
configuration. Enter Y if you are sure you want to proceed. ? [no]: yes  (Enter)
Loading rcs3600-confg.cfg !
[OK - 1792/4096 bytes]
Total number of passes: 1
Rollback Done
Nov 26 19:38:07.507: Rollback:Acquired Configuration lock.

***Note:
The best way to replace configuration (Recommendation
1)erase startup-config
2)reload router
3)paste new configuration
4)copy running-config startup-config