Got it

Questions about TTL

Created: May 26, 2020 14:21:32Latest reply: Jul 30, 2020 21:35:41 2062 17 0 0 0
  Rewarded HiCoins: 3 (problem resolved)

Hi guys,

I have just browsed this post, https://forum.huawei.com/enterprise/en/using-the-ttl-qos-feature/thread/624167-863 and it has reminded me a question that bothers me a lot....

I know that the router will not accept IP packets with TTL = 0. I want to know after receiving the packet, will the router first decrement the TTL and then judge, or judge and then decrement the TTL? In other words, will the router process packets with TTL=1?

In addition, can a packet with TTL = 1 reach the interface loopback0 of the router? And will the TTL change after NAT?


Featured Answers
Popeye_Wang
Admin Created May 26, 2020 14:33:21

First, the router will certainly receive and reply packets with TTL = 1.
Then about loopback0. I have explained in the post here: https://forum.huawei.com/enterprise/en/ebgp-max-hop/thread/610378-863

In fact, the forwarding process on the routers is as follows: When the RT1 sends packets, If a valid address of any local interface is used as the source address, the router searches the routing table and forward packet based on the outbound interface. The routing table is used to forward packets, so the processing here can be considered as a hop. After the packet reaches the RT2, the router does not search for the routing table. Instead, the router finds that the destination address of the packet is the local address, even if the destination address is not the address of the inbound interface, the packet is directly sent to the CPU for processing.

Therefore, even if the loopback address of the peer router is pinged, there is only one hop for the forwarding.

Another explanation: According to RFC 791 (IPv4) and RFC 2460 (IPv6), the TTL value decreases by 1 each time a packet is forwarded by a node. Packets are not forwarded through the loopback interface. Therefore, the TTL value is not reduced. The TTL value of 1 is sufficient.

Finally, NAT only changes the address of the packet, and other parameters, including the TTL, remain unchanged.

I hope this helps.

View more
  • x
  • convention:

Unicef
Unicef Created Mar 17, 2022 07:25:37 (0) (0)
NOTE  
All Answers
Hello.
Kindly wait for a momentQuestions about TTL-3317295-1
View more
  • x
  • convention:

First, the router will certainly receive and reply packets with TTL = 1.
Then about loopback0. I have explained in the post here: https://forum.huawei.com/enterprise/en/ebgp-max-hop/thread/610378-863

In fact, the forwarding process on the routers is as follows: When the RT1 sends packets, If a valid address of any local interface is used as the source address, the router searches the routing table and forward packet based on the outbound interface. The routing table is used to forward packets, so the processing here can be considered as a hop. After the packet reaches the RT2, the router does not search for the routing table. Instead, the router finds that the destination address of the packet is the local address, even if the destination address is not the address of the inbound interface, the packet is directly sent to the CPU for processing.

Therefore, even if the loopback address of the peer router is pinged, there is only one hop for the forwarding.

Another explanation: According to RFC 791 (IPv4) and RFC 2460 (IPv6), the TTL value decreases by 1 each time a packet is forwarded by a node. Packets are not forwarded through the loopback interface. Therefore, the TTL value is not reduced. The TTL value of 1 is sufficient.

Finally, NAT only changes the address of the packet, and other parameters, including the TTL, remain unchanged.

I hope this helps.

View more
  • x
  • convention:

Unicef
Unicef Created Mar 17, 2022 07:25:37 (0) (0)
NOTE  
Posted by Popeye_Wang at 2020-05-26 14:33 First, the router will certainly receive and reply packets with TTL = 1.Then about loopback0. I have ...
Interesting question, nice answer.
View more
  • x
  • convention:

Hi,

TTL Value in ip header decreases o when device forward packet to outbound via interfaces.For loopback interfaces no need to decrease TTL value because device doesn't forward packet,it just process it's on CPU.

In addition,device could receieve an IP packet with TTL value 1 or 0,when it's one it means device Forwarding Plane can process data,when TTL 0 Forwarding Plane can't forward this ip packet.
View more
  • x
  • convention:

Unicef
Unicef Created Mar 17, 2022 07:25:47 (0) (0)
COOL  
hmmm
View more
  • x
  • convention:

good
View more
  • x
  • convention:

nice
View more
  • x
  • convention:

thanks for sharing
View more
  • x
  • convention:

Thanks for your reply. But your opinions are quite different. So can you further explain about the TTL = 1?
View more
  • x
  • convention:

12
Back to list

Comment

You need to log in to comment to the post Login | Register
Comment

Notice: To protect the legitimate rights and interests of you, the community, and third parties, do not release content that may bring legal risks to all parties, including but are not limited to the following:
  • Politically sensitive content
  • Content concerning pornography, gambling, and drug abuse
  • Content that may disclose or infringe upon others ' commercial secrets, intellectual properties, including trade marks, copyrights, and patents, and personal privacy
Do not share your account and password with others. All operations performed using your account will be regarded as your own actions and all consequences arising therefrom will be borne by you. For details, see " User Agreement."

My Followers

Login and enjoy all the member benefits

Login

Block
Are you sure to block this user?
Users on your blacklist cannot comment on your post,cannot mention you, cannot send you private messages.
Reminder
Please bind your phone number to obtain invitation bonus.