Set the telnet source IP address for a Cisco router

Contributor Icon Contributed by qmchenry  
Tag Icon Tagged: Cisco router  

The default source IP address when telnetting from a Cisco router is that of the interface closest to the destination. Because some access lists may block traffic from the default IP address, or to help test access lists, it may be useful to temporarily or permanently set the telnet source IP address.


To temporarily set the telnet source IP address for a single telnet session, use the /source-interface extension to the telnet command. For example, to telnet to 192.168.1.4 using the source IP address of the interface FastEthernet0

telnet 192.168.1.4 /source-interface FastEthernet0

To set this interface as the source IP address for all telnet sesions, use this command in configuration mode (conf t):

ip source-interface fastethernet0

 

5 Comments -


  1. great idea said on October 29, 2008

    Brilliant tip, got me out of a hole tonight!

  2. Mike said on May 19, 2010

    Anything similar for SSH?

  3. Richey said on December 8, 2010

    This command did not work on a box with 12.3. I used “ip telnet source-interface interface fa0/0″

  4. Satyadevan W said on March 25, 2011

    how to assign an ipaddress for auxiliary port in a router

  5. mike said on October 2, 2011

    Thx dude

 

RSS feed for comments on this post. TrackBack URL

Leave a comment -