Options

Ping your own interface

CiscopimpenatorCiscopimpenator Inactive Imported Users Posts: 134
What happens when you ping your own IP interface?

According to this .pdf, when you ping your own interface with point-to-point links you are successful, but with Frame Relay links which aren't mapped you don't get success.

http://www.ciscokits.com/frame_relay/1.pdf <
Good FAQ on Frame-Relay


On my windows box, if I ping my own IP address the gateway is 127.0.0.1, which is the loopback or the TCP/IP stack correct?

So on a Cisco router when you ping your own IP address, assuming you use the default ping command(not extended ping) the router sends an ICMP echo to another destination? That is what the article said. I'm kind of confused why the router would do something like this. I mean, if the source is the same as the destination wouldn't the router just ping the local IP stack without sending traffic over the link. I guess my understanding of ICMP is not as good as I thought.

Thanks for help :)

-Ciscopimpenator
-Ciscopimpenator

Comments

  • Options
    CiscopimpenatorCiscopimpenator Inactive Imported Users Posts: 134
    I did some research and Cisco routers, when they ping their own interface, send icmp echo's across across the link.

    Now I need to find out how they get this to work.

    Later on...

    I found out the routing algorithm cares about destination address, not source(which makes sense). Therefore the ICMP packet will be routed out to the appropriate subnet. The router throws the packet out the interface and hopefully the next hop router throws it back(because the next hop router should have a route for this subnet or ip address.


    -Ciscopimpenator
    -Ciscopimpenator
  • Options
    Paul BozPaul Boz Member Posts: 2,620 ■■■■■■■■□□
    Where did you find that? I'd love to read up on it if you can link your sources.
    CCNP | CCIP | CCDP | CCNA, CCDA
    CCNA Security | GSEC |GCFW | GCIH | GCIA
    pbosworth@gmail.com
    http://twitter.com/paul_bosworth
    Blog: http://www.infosiege.net/
  • Options
    EdTheLadEdTheLad Member Posts: 2,111 ■■■■□□□□□□
    This is not a FR issue, it happens on a standard hdlc serial interface.If you ping your local serial interface, the ping will transverse the physical line and get return by the farend, so pinging your own serial isn't a way toconfirm your local ip stack.
    Networking, sometimes i love it, mostly i hate it.Its all about the $$$$
  • Options
    CiscopimpenatorCiscopimpenator Inactive Imported Users Posts: 134
    So you can map two ip addresses to the same DLCI??
    I guess it works if the second address is your local outgoing interface.

    Good tip!

    I knew you could do the opposite...
    -Ciscopimpenator
  • Options
    CiscopimpenatorCiscopimpenator Inactive Imported Users Posts: 134
    EdTheLad wrote:
    This is not a FR issue, it happens on a standard hdlc serial interface.If you ping your local serial interface, the ping will transverse the physical line and get return by the farend, so pinging your own serial isn't a way toconfirm your local ip stack.

    It's a routing issue.
    -Ciscopimpenator
  • Options
    darkuserdarkuser Member Posts: 620 ■■■□□□□□□□
    it's not a routing issue since it will work or not work with or without a routing protocol running.
    think about it ... your layer 2 "connection" or pvc is to the remote fr switch.
    you can verify layer2 is working by sh fram map and sh fram pvc.
    since fr has no concept of "arp" like ethernet we only have two choices to map layer 3 to layer 2.
    1. dynamic mapping with inverse arp
    2. static mapping.
    point-to-point interfaces always work because the destination is the other end of the link.
    multi-point interfaces (physical or multipoint sub) need dynamic (or static) mappings to all points you'd like to forward to. dynamic can't resolve your own local ip so have have to staticly map your own ip to the local dlci .... for the reasons already stated ... all so the remote router can do an icmp redirect and the "pinging" router can resolve itself.
    rm -rf /
  • Options
    CiscopimpenatorCiscopimpenator Inactive Imported Users Posts: 134
    All you really needed to say was this
    "all so the remote router can do an icmp redirect and the "pinging" router can resolve itself"


    When I say routing issue I mean routing as in "routing function" not routing protocols.

    The routing function of the IOS decides to send the packet out the interface with the subnet in mind.

    For example:

    You ping 192.168.1.1 which is the same ip address of your outgoing interface

    The routing table see this

    192.168.1.0 is directly connected, Serial 0


    The routing function decides to send the packet out the interface Serial 0. The other router routes the packet back. The end result is you ping your own interface, but not until it reaches the neighboring router and gets redirected.


    Comprende? icon_cool.gif
    -Ciscopimpenator
  • Options
    CiscopimpenatorCiscopimpenator Inactive Imported Users Posts: 134
    darkuser wrote:
    it's not a routing issue since it will work or not work with or without a routing protocol running.
    think about it ... your layer 2 "connection" or pvc is to the remote fr switch.
    you can verify layer2 is working by sh fram map and sh fram pvc.
    since fr has no concept of "arp" like ethernet we only have two choices to map layer 3 to layer 2.
    1. dynamic mapping with inverse arp
    2. static mapping.
    point-to-point interfaces always work because the destination is the other end of the link.
    multi-point interfaces (physical or multipoint sub) need dynamic (or static) mappings to all points you'd like to forward to. dynamic can't resolve your own local ip so have have to staticly map your own ip to the local dlci .... for the reasons already stated ... all so the remote router can do an icmp redirect and the "pinging" router can resolve itself.

    ARe you sure the remote router does an ICMP redirect?
    -Ciscopimpenator
  • Options
    darkuserdarkuser Member Posts: 620 ■■■□□□□□□□
    darby ... thanks i was just trying to add a layer of clarity to the topic.
    trust me i didnt make this up im having to re-read old topics that i assumed i mastered.

    nmc1 binder page 92-93 "pinging a locally assigned ip address"

    it absolutely does an icmp redirect.... but you cant see it due to fast cache you have to disable
    ip route-cache to actually see it happen.
    rm -rf /
  • Options
    milliampmilliamp Member Posts: 135
    The behavior to send these packets outbound rather than treat it as loopback is useful for troubleshooting an interface that is taking errors.
  • Options
    darkuserdarkuser Member Posts: 620 ■■■□□□□□□□
    i feel you man .....
    i meant in the context of the others person's response not yours
    you aggreed with me .... as you can tell ive spend wayyyy too much time on fr .....
    i have to make an attempt by sept or ill be taking the written a third time ...
    rm -rf /
Sign In or Register to comment.