Reduce the noise generated by the Cisco IOS copy command

I always hate it when Cisco IOS asks me for things I've already supplied in a command line, the most notable case being the copy command. For example, if you supply the complete source and destination file name in the command line, IOS still insists on asking you all the same questions (at least filling in the parameters I've supplied in the command line):
fw#copy system:running-config tftp://10.0.0.2/fw-test
Source filename [running-config]?
Address or name of remote host [10.0.0.2]?
Destination filename [fw-test]?
!!
2009 bytes copied in 0.604 secs (3326 bytes/sec)
You can disable the annoying questions with the file prompt quiet configuration command (the default value of this parameter is noisy).
fw#configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
fw(config)#file prompt quiet
fw(config)#^Z
fw#copy system:running-config tftp://10.0.0.2/fw-test
!!
2009 bytes copied in 0.616 secs (3261 bytes/sec)
However, if you decide to use this configuration command, you might be surprised by its side effects - whenever you don't specify a parameter, the router tries to use its default value and you might not like what you get. Consider this sequence:
fw#copy system:running-config tftp:
Address or name of remote host []? 10.0.0.2
!!
2009 bytes copied in 0.600 secs (3348 bytes/sec)
Could you guess what the remote file name is in this case? I couldn't and had to look into the TFTP server log. Turns out the router uses router-name-confg as the default file name.

3 comments:

  1. Hi Ivan ,
    this methode can work with the extended ping or not ?
    R#ping
    Protocol [ip]: ip
    Target IP address: 1.1.1.1
    Repeat count [5]: 5
    Datagram size [100]:

    i try but not working
    can you gave me a help ??????
  2. Try this:

    http://blog.ioshints.info/2007/03/one-line-extended-ping.html
  3. The default for file prompt is "alert" not "noisy". I'm not sure if this is something that has changed since you wrote this post.
Add comment
Sidebar