Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

WCF-SocketException: An existing connection was forcibly closed by

144 views
Skip to first unread message

Murthy

unread,
Sep 18, 2008, 1:31:01 PM9/18/08
to

Hi,
I have created an WCF service to transfer files between my window mobile 6.0
device and the server.
It works fine for files up to 2MB, But when i try to send larger files, it
throws the below exception.

[System.Net.WebException] = {"Unable to read data from the transport
connection."}

{System.Net.Sockets.SocketException: An existing connection was forcibly
closed by the remote host
at System.Net.Sockets.Socket.SendNoCheck(Byte[] buffer, Int32 index,
Int32 size, SocketFlags socketFlags)
at System.Net.Sockets.Socket.Send(Byte[] buffer, Int32 offset, Int32
size, SocketFlags socketFlags)
at System.Net.Connection.Write(Byte[] buffer, Int32 offset, Int32 count)
at System.Net.HttpWebRequest.WriteConnectStream.NetworkWrite(Byte[] data,
Int32 offset, Int32 length)
at System.Net.HttpWriteStream.Write(Byte[] bytes, Int32 offset, Int32
length)
at System.Net.HttpWriteStream.copyTo(HttpWriteStream target)
at System.Net.HttpWebRequest.startSending()
at System.Net.HttpWebRequest.startReceiving(Connection connection)
at System.Net.Connection.startReceiving(Object ignored)
at System.Threading.ThreadPool.WorkItem.doWork(Object o)
at System.Threading.Timer.ring()
}

NativeErrorCode = 10054

I tried setting receiveTimeout="01:00:00" sendTimeout="01:00:00" in web.config
Still the i get the exception after 15 Seconds.

Any idea how i can resolve the above error?

Thanks,
Murthy

HCH

unread,
Oct 7, 2008, 3:15:44 PM10/7/08
to

If you are going over cellular, which network are you using? What
port are you using?

chriswigley

unread,
Dec 4, 2009, 11:36:16 AM12/4/09
to
Hi Murth,

I was wondering if you ever found a solution to this problem. I am attempting to do the same thing now and running into this exact 2mb limitation. Any ideas would be appreciated.

Murth wrote:

WCF-SocketException: An existing connection was forcibly closed by
18-Sep-08

NativeErrorCode = 10054

Thanks,
Murthy

Previous Posts In This Thread:

On Thursday, September 18, 2008 1:31 PM
Murth wrote:

WCF-SocketException: An existing connection was forcibly closed by

NativeErrorCode = 10054

Thanks,
Murthy

On Tuesday, October 07, 2008 10:13 PM
HCH wrote:

Re: WCF-SocketException: An existing connection was forcibly closed by
6.0
t
x,
32
count)
] data,
t32
eb.config

If you are going over cellular, which network are you using? What
port are you using?


Submitted via EggHeadCafe - Software Developer Portal of Choice
Obfuscation and Packaging of .NET Applications via Compressed Embedded Assemblies
http://www.eggheadcafe.com/tutorials/aspnet/04aa7525-f153-4907-b0e8-10ac501f430a/obfuscation-and-packaging.aspx

0 new messages