I'm working on a project which uses .NET Remoting for communication between the client application and an object server. For development, the client, server, and MSSQL database are all running on my local development machine.

When I'm working at the office, the responsiveness is just fine.

However, when I work from home the speed is significantly slower. If I disconnect from the VPN, it speeds up (I believe, but maybe that's just wishful thinking). If I turn off my wireless connection completely it immediately speeds up to full throttle.

My assumption is that the remoting traffic is being routed through some point that is slowing everything down, albeit my home router and/or the VPN.

Does anyone have any ideas of how to force the remoting traffic to remain completely localized?


Is the local server on your dev pc being accessed by name or IP address. The issue could be related DNS resolution.


I worked on a project last summer that required some pretty heavy modifications to .NET Remoting. I don't remember all the specifics, but if we had more than one network interface, we couldn't get the out-of-the-box Remoting implementation to reliably detect which one the Remoting traffic came from, which did horrible things to performance. This sounds like a similar, if not the same, issue.

Jason Sparks

Have you tried a tracert to see if the VPN or the wireless is adding some extra hops?

Ralph Willgoss

I tried using both localhost and in the client configuration, both had the performance problems.

Donovan Woodside

I don't have any VPN connections on my current computer but somewhere in the TCP/IP properties for the connection there's a checkbox to indicate that you use the remote host as a gateway or something like that.

This once caused me alot of issues since all my traffic would go over the VPN and then back again, even when I wanted to do something locally.

Ralph Willgoss
+2  A: 

Perhaps during development you could use an IPC remoting channel which uses named pipes instead of TCP. If your remoting channels are set up via a config file then you won't even have to recompile.

I found the link below was useful when setting up an IPC channel.

+1  A: 

I had this same problem where immediately when you disconnect things are tremendously better.

If you are using windows VPN, you have to change a default setting. It will force a connection to use the remote router as your gateway while connected. If you go to properties for the connection, then to the networking tab. Select TCP/IPv4 and go to properties. In this window select Advanced... and there will be an option to use the default gateway on the remote network, make sure this is NOT checked. This should help immensely.