LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software > Linux - Kernel
User Name
Password
Linux - Kernel This forum is for all discussion relating to the Linux kernel.

Notices


Reply
  Search this Thread
Old 07-16-2012, 01:36 PM   #1
dhavey
LQ Newbie
 
Registered: Jun 2012
Posts: 9

Rep: Reputation: Disabled
TCP resends and behaves as if there was no loss?!?


Does anybody understand this Linux kernel behavior?

I drop packets with a tool like tc or ethtool on the sending host and the kernel magically replaces them!

I understand that the solution is to drop the packets somewhere else rather than the sending host. However, this is magical and decidedly non-scientific.

Personally, I am content with the magical behavior. I could care less if Linux leprechauns in the kernel are sprinkling fairy dust on the packets and causing them to magically regenerate themselves!

However, when I try to explain to my various bosses that I need another piece of hardware because of the Linux leprechauns, well, ummm, yeah, sounds like penguin poop!

Does anybody know why this happens? Or better yet, where is the code that does this? Is this legacy behavior? Is it an optimization? What is the purpose? Did the old skool kernel koders think that the stack would drop packets by accident?

I guess that could happen if we overflowed a buffer on our own stack, but, wouldn't TCP's congestion control behavior be the correct thing to do? Instead of just replacing my packet without telling anyone?

Hmmmm...

This is an excerpt from the linuxfoundation.org's page on netem:
http://www.linuxfoundation.org/colla...tworking/netem

Caveats

When loss is used locally (not on a bridge or router), the loss is reported to the upper level protocols. This may cause TCP to resend and behave as if there was no loss. When testing protocol reponse to loss it is best to use a netem on a bridge or router.

...Daniel
PS...I hope this is an apropos forum for Linux TCP kernel questions. I thought linux networking was a good one, but, they don't seem to think so.
 
Old 07-16-2012, 08:34 PM   #2
frankbell
LQ Guru
 
Registered: Jan 2006
Location: Virginia, USA
Distribution: Slackware, Ubuntu MATE, Mageia, and whatever VMs I happen to be playing with
Posts: 19,323
Blog Entries: 28

Rep: Reputation: 6141Reputation: 6141Reputation: 6141Reputation: 6141Reputation: 6141Reputation: 6141Reputation: 6141Reputation: 6141Reputation: 6141Reputation: 6141Reputation: 6141
I'm not exactly sure that this answers your question, but the TCP specification anticipated and compensates for dropped packets.

https://en.wikipedia.org/wiki/TCP_gl...ynchronization
 
Old 07-17-2012, 11:49 AM   #3
dhavey
LQ Newbie
 
Registered: Jun 2012
Posts: 9

Original Poster
Rep: Reputation: Disabled
Hmmm, doesn't seem like normal TCP behavior to me.

Tc is an ip layer tool. This is below TCP. How would TCP know about the losses? There are only 2 mechanisms in the RFC. RTO's and duplicate ACKs. Wireshark shows no duplicate ACKs. RTO's would hose the connection for sure.

Also why would the behavior become normal when tc is dropping packets on another host? Hmmmmm...


Nope, this is non-standard, and (AFAIK) undocumented. I guess I will have to muck around with the tc code someday. I was just hoping somebody might have some sort of clue...

...Daniel
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Monitoring TCP Packet Loss in NS2 yida Linux - Networking 4 06-25-2010 07:06 AM
evolution resends prior day email upon reboot rholme Linux - General 6 11-07-2009 06:39 AM
Partial loss of internet connectivity (TCP window scaling?) ojbyer@usa.net Linux - Networking 5 11-30-2008 12:46 PM
How to track TCP/UDP Packet loss for certain period ? neel.gurjar Linux - Networking 2 07-20-2008 01:05 AM
Configuring the way mandrake 9.2 looks/behaves.. tinaldor Mandriva 7 11-14-2003 04:49 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software > Linux - Kernel

All times are GMT -5. The time now is 09:47 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration