2

Recently we ran into what looked like a connectivity issue when a particular customer of ours installed our product. We ultimately traced it to a low MTU (~1300 bytes) being configured on one of the devices in the network. In this particular deployment, we had two Windows machines running our application communicating with one another, and their link MTUs were set at 1500.

One thing that made this particularly difficult to troubleshoot, was that our application would work fine during the handshake phase (where only small requests are sent), but would sometimes fail sending a specific request of size ~4KB across the network. If it makes a difference, the application is written in C# and these are WCF messages.

What could account for this indeterminism? I would have expected this to always fail, as the message size we were sending was always larger than the link MTU perceived by the Windows client, which would lead to at least one full 1500-byte packet, which would lead to problems. Is there something in TCP that could make it prefer smaller packets, but only sometimes?

Some other things that we thought might be related:

1) The sockets were constantly being set up and torn down (as the application received what it interpreted as a network failure), so this doesn't appear to be related to TCP slow start.

2) I'm assuming that WCF "quickly" pushes the entire 4KB message to the socket, so there's always something to send that's larger than 1500 bytes.

3) Using WireShark, I didn't spot any TCP retransmissions which might explain why only subsets of the buffer were being sent.

4) Using WireShark, I saw a single 4KB IP packet being sent, which perhaps indicates that TCP Segment Offloading is being implemented by the NIC? (I'm not sure how TSO would look on WireShark). I didn't see in WireShark the 4KB request being broken down to multiple IP packets, in either successful or unsuccessful instances.

5) The customer claims that there's no route between the two Windows machines that circumvents the "problematic" device with the small MTU.

Any thoughts on this would be appreciated.

YSK
  • 1,572
  • 10
  • 19
  • Well, at application level, TCP is a byte stream, so MTU, packet sizes, segmentation etc. is largely irrelevant. TCP cannot transfer any messages larger than one byte. – Martin James Jul 24 '15 at 22:17
  • @MartinJames well, yes, but ultimately the data is sent over IP packets. It seemed like there was variance in the eventual packet sizes that were used, which complicated the analysis - hence my question. – YSK Jul 24 '15 at 22:48
  • 1
    Your application failed how? Sounds like it is over sensitive to me. It shouldn't care about packet sizes, as it can't even see them. Post some code. – user207421 Jul 24 '15 at 23:05
  • This is unlikely to be the classic read bug. WCF surely does not have it. That's a red herring. – usr Jul 24 '15 at 23:28
  • 1
    "fail" What do you mean by that? Post the full exception ToString. – usr Jul 24 '15 at 23:28
  • 1
    If a framework uses TCP as transport, MTU/segmentation/packets should be irrelevant. If the characteristics of a TCP transport affect the functionality, (as distinct from performance), of the service, then the framework/transport are not communicating correctly. – Martin James Jul 25 '15 at 01:02
  • @usr What red herring? Who said anything about a classic read bug? – user207421 Jul 25 '15 at 02:09

0 Answers0