Using FTP from the Router
Problem
You want to use FTP directly from your router to download configuration or IOS files.
Solution
The copy ftp: command lets the router exchange files using FTP:
Router1#configure terminalEnter configuration commands, one per line. End with CNTL/Z. Router1(config)#ip ftp usernameRouter1(config)#ijbrownip ftp passwordRouter1(config)#ianpasswordendRouter1#copy ftp: running-configAddress or name of remote host [172.25.1.1]?Source filename []?172.25.1.1Destination filename [running-config]?test<enter>Accessing ftp://172.25.1.1/test... Loading /test [OK - 24/4096 bytes] 24 bytes copied in 0.276 secs (87 bytes/sec) Router1#
Notice that we explicitly defined a username and password in this example. If you don’t specify a username, the router will try to connect to the server’s anonymous FTP service.
Discussion
Several recipes in this chapter have shown how to transfer files between your router and server by using TFTP. However, Cisco routers also support FTP. We find that FTP is better suited for transferring files over busy and congested links. While TFTP file transfers tend to abort if they encounter persistent congestion, FTP appears to be more resilient.
FTP is also somewhat more secure than TFTP because it uses usernames and passwords. TFTP has no user-level security features. However, FTP sends its passwords across the network in unencrypted cleartext, so it is still not highly secure.
In the example, we explicitly configured a FTP username and ...