Exceeding MTU which serialized tcp messages

M

M4tt

Hi, I am writing a client/server application that has quite complex
messages that can only reasonably be handled by parsing serialized
message class objects using a networkstream and binaryformatter. when
the message objects are less than the MTU (1500b) then message is
correctly deserialized at the recieving end. when the message exceeds
1500b the packet is completely dropped and only 1byte is received at
the other end. Ethereal confirms the dropped packet.

i would have thought .Net sockets class would hand splitting the data
transmittion into packets that do not exceed the MTU but it doesn't by
default. is there anything i need to set to make this happen because
the application works beautifully when client and server run on the
same machine and it would be a lot of work to re-write the messages to
make them less than 1500b.

Thanks in advance for any help with this.

Regards,
Matthew
 
J

John Duval

Hi Matthew,
Sounds like you might have a "black hole router" problem. You might
want to read this:
http://groups.google.com/group/micr...rosoft.public.*&rnum=8&hl=en#45c02620cf76eb2a

Another option is to try this (this worked for me in a similar
situation):

1) Run Regedit
2) Navigate to:
HKEY_LOCAL_MACHINE \ SYSTEM \ CurrentControlSet \ Services \ TCPIP \
Parameters \ Interfaces \

Highlight the correct interface by looking for the active IP Address,
add a REG_DWORD with value MTU and add decimal data 1492

Reboot after change. Depending on the type of network connection, you
might need to do smaller MTU values (e.g. 1472).

You can test the MTU along a path by using PING to see how low you have
to go:
ping -f -l 1472 x.x.x.x

This is not a .NET problem, it's lower down.

Hope that helps,
John
 
M

M4tt

Thanks John. We will try this out.

John said:
Hi Matthew,
Sounds like you might have a "black hole router" problem. You might
want to read this:
http://groups.google.com/group/micr...rosoft.public.*&rnum=8&hl=en#45c02620cf76eb2a

Another option is to try this (this worked for me in a similar
situation):

1) Run Regedit
2) Navigate to:
HKEY_LOCAL_MACHINE \ SYSTEM \ CurrentControlSet \ Services \ TCPIP \
Parameters \ Interfaces \

Highlight the correct interface by looking for the active IP Address,
add a REG_DWORD with value MTU and add decimal data 1492

Reboot after change. Depending on the type of network connection, you
might need to do smaller MTU values (e.g. 1472).

You can test the MTU along a path by using PING to see how low you have
to go:
ping -f -l 1472 x.x.x.x

This is not a .NET problem, it's lower down.

Hope that helps,
John
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top