cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Announcements

Ask the Expert- SD-WAN

2672
Views
5
Helpful
31
Replies
Beginner

Self ping serial interface

Hi,

If we have 2 routers,

rtrA serial IP address 1.1.1.1

rtrB serial IP address 1.1.1.2

both the serial ports are connected through a leased line.

If i ping 1.1.1.1 from rtrA the delay is around 36ms, and if i ping 1.1.1.2 from rtrA the delay is around 18 ms,

i guess if i do a self ping on the serial interface, it goes till the next ip address and returns back.

also if the serial link is down, the self serial ip address is not able to ping itself.

kindly explain the logic behind it.

Sai.

1 ACCEPTED SOLUTION

Accepted Solutions
Advocate

Re: Self ping serial interface

That is right, the ping goes out and back. This is done so that you can do a loopback test on the serial lines. But this behaviour only applies if you ping from within the router. If you ping 1.1.1.1 from a host connected to, say, the Ethernet of router A, then the router will just look at its serial line, see that it is up, and respond to the ping directly. In either case, if the serial interface is down, then there will be no response to the ping.

Kevin Dorrell

Luxembourg

31 REPLIES 31
Advocate

Re: Self ping serial interface

That is right, the ping goes out and back. This is done so that you can do a loopback test on the serial lines. But this behaviour only applies if you ping from within the router. If you ping 1.1.1.1 from a host connected to, say, the Ethernet of router A, then the router will just look at its serial line, see that it is up, and respond to the ping directly. In either case, if the serial interface is down, then there will be no response to the ping.

Kevin Dorrell

Luxembourg

Beginner

Re: Self ping serial interface

Hi Kevin,

Thank you for the reply,

can you please explain in details please and also what happens if i ping the ethernet from the same router?

Sai.

Advocate

Re: Self ping serial interface

Sai,

A serial line can do a loopback test as I described because it is point-to-point. One point I forgot to mention of course is that it only works on point-to-point encapsulation, e.g. HDLC and PPP. It will not work on Frame Relay and X.25. But I think it may work on a Frame Relay point-to-point subinterface - I'll have to try it to be sure.

In the case of Ethernet, the behaviour is different. Because it is multi-access, there is no "other side" to loop back the ping packet. So the router just looks to see if the line protocol is "up", and if it is, it answers the ping itself.

Kevin Dorrell

Luxembourg.

Beginner

Re: Self ping serial interface

thanks kevin,,

u have given the best possible explaination..

Sai.

Hall of Fame Master

Re: Self ping serial interface

Actually it DOES work to ping your own IP address over Frame Relay (both point-to-point and multi-point). If you want to ping your own address on multi-point you must have a frame relay mapping that associates your IP address with one of the outbound PVCs.

In this case the ping is sent out over the appropriate PVC and the remote router returns it. And then the ping response is sent over the appropriate PVC and the remote router returns it. And that is why the time to ping your own IP address will be twice the amount of time needed to ping the remote router address.

HTH

Rick

Advocate

Re: Self ping serial interface

OK, thanks for that information Rick. I thought that it might work for point-to-point, but I didn't see how to do it in multi-point, and I didn't have time yet to try it in the lab.

I see your comment about associating a DLCI with your own local address applies only to the multi-point case - in the point-to-point case you don't have a map command as such, so I guess the association is implied.

I guess it is also important to remember that in the multi-point case it only tests one of the DLCIs, the one you associated to your own address.

Kevin Dorrell

Luxembourg

Hall of Fame Master

Re: Self ping serial interface

Kevin

It works just fine for both point to point and multipoint. If there is a point to point subinterface, then the relationship of IP address and DLCI is unambiguous and the router knows exactly on to which DLCI to put the data. On a multi point (this includes multi point subinterfaces and the main interface) you must explicitly associate your own IP address with a DLCI.

And yes if you do this on a multi point you will only test one DLCI. (But I am not sure that you usually ping your own interface as a way to test a DLCI.)

HTH

Rick

Highlighted

Re: Self ping serial interface

Hello,

I have seen one such incident, as you guys discussing on ping response on serial interface. As you say, ping to routers own serial IP, it goes through link and comes back to itself.

Once I had a problem with my internet connection, I was troubleshooting with that. Interface was UP, still wasn’t able access internet.

So I was trying to ping my serial IP from outside, website which provide network tools for internet (I was considering some routing issue at ISP side). When the interface is UP, then it’s OK that I was getting reply for my IP and for ISP end serial IP.

But when I purposefully made the interface down, after that also I was getting reply for my serial IP and next IP/ISPs router IP (obviously both have IP of same subnet).

I conformed this with ISPs engineer. That means ISPs router was responding for both IPs.

I can understand ISP router responds for its own serial IP of my subnet, but how can that router respond to my serial IP?

Beginner

Re: Self ping serial interface

Hi Guys,

i am not able to clearly understand the time parameter..

why it takes double the time to ping the own interface..

Sai.

Advocate

Re: Self ping serial interface

When you ping the other guy's interface, the ping goes out, and the response comes back - 2 journeys.

When you ping your own interface, the ping goes out to the other guy and back to you, you respond, and the response goes out to the other guy and back - 4 journeys.

Hope this helps (now that I understand it a bit better, thanks to Rick.)

Kevin Dorrell

Luxembourg.

Beginner

Re: Self ping serial interface

kevin,

sorry for eating ur head,

u said "When you ping your own interface, the ping goes out to the other guy and back to you, you respond, and the response goes out to the other guy and back - 4 journeys"

when i ping myself, if the ping goes out to the other guy and comes back to me, i guess the ping should end there, why should the respond back?

Sai..

Advocate

Re: Self ping serial interface

Sai,

Didn't notice. Must be getting more thick-skinned. That's good. ;-)

That's what tripped me up first time I thought about it, as well. The ping packet is addressed from you (10.1.1.1) to yourself (10.1.1.1), but because it is generated in the router itself, it goes the long way round, via 10.1.1.2. So it is quite logical that the reply, which is also internally generated from you (10.1.1.1) to yourself (10.1.1.1), should also take the same path via 10.1.1.2.

(Can't remember whether these were the addresses we used in the original example, but you get the point.)

Kevin Dorrell

Luxembourg

Rising star

Re: Self ping serial interface

What is the encapsulation setting on the point-to-point circuit ?

Is the self ping behavior when using hdlc

the same with the behavior you get with ppp ?

I suspect something here, but I cannot verify it with some equipment,

so I would appreciate if anyone could do this test.

Thanks in advance,

M.

Hall of Fame Master

Re: Self ping serial interface

You get the same behavior on any point to point connection, whether it is HDLC, or PPP, or point to point Frame Relay. When you ping your own interface address the ping packet is sent out the interface to the neighbor. The neighbor recognizes a packet whose destination is on a connected network and forwards it back to you. You receive the ping request and recognize that it is addressed to you and generate a response. the response packet is sent out the interface, received by the neighbor and forwarded to you. 4 trips.

good work Kevin in explaining this the first time.

HTH

Rick

CreatePlease to create content
Content for Community-Ad
July's Community Spotlight Awards