When should the timer start when sending a frame in data link layer?

xenonn

Distinguished
Sep 23, 2011
29
0
18,530
I read from the books that when the frames are being sent from one end to another in the data link layer, there is a timer being started when ever a frame is being sent out. This is for the layer to know if it needs to resend a particular frame or not.

But I am wondering should the timer be started at the beginning when the very first bit of the frame is sent out or at the very end when the last bit of the frame is sent out?

In the book, it has a diagram that looks like the one below. The clock icon at the left signifies the start of the timer. However, it doesn't show explicitly if it should start at which point. I have indicated the transmission of the first bit of the frame and the last bit of the frame with point X (at the start of the frame) and point Y (at the end of the frame) respectively.

ibfZaTf7gZUPM.png

Should the timer start at Point X or Point Y? I am guessing that it should start at Point Y to be fair but I'm not sure.
 
Solution
It should start at Point X.

Think of it this way. Let's say you have a loading bar that goes from left to right:
[____________] (this is blank, i.e. at 0%)
The moment you start sending something it would look like this on a wire:
[X___________]
Now that would be Point X. If you started the timer at point Y, that would only be counting since the LAST bit entered the medium. Starting the timer at this time:
[YXXX________]
Would be like starting a timer when the last group of runners left the starting line at a marathon (great analogy I know 😉 )
It should start at Point X.

Think of it this way. Let's say you have a loading bar that goes from left to right:
[____________] (this is blank, i.e. at 0%)
The moment you start sending something it would look like this on a wire:
[X___________]
Now that would be Point X. If you started the timer at point Y, that would only be counting since the LAST bit entered the medium. Starting the timer at this time:
[YXXX________]
Would be like starting a timer when the last group of runners left the starting line at a marathon (great analogy I know 😉 )
 
Solution
I believe you are looking for the TTL - Time to Live. Go out and ping a website and you will see the time to live 'timer.' Once the packet is sent - it is small, so there really isn't a start or end of the packet, it isn't like transferring a 1GB file, the file is broken down into a huge amount of frames/packets.