Page 1 of 1

Existing connection was forcibly closed by the remote host

Posted: Wed 24 Feb 2016 2:01 am
by stephenord
I have only just taken the plunge with CumulusMX but got everything setup quite easily, thanks to some excellent posts on here! However I seem to be getting a problem with:

2016-02-23 21:58:07.416 System.IO.IOException: Unable to write data to the transport connection: An existing connection was forcibly closed by the remote host. ---> System.Net.Sockets.SocketException: An existing connection was forcibly closed by the remote host
at System.Net.Sockets.Socket.Send(Byte[] buffer, Int32 offset, Int32 size, SocketFlags socketFlags)
at System.Net.Sockets.NetworkStream.Write(Byte[] buffer, Int32 offset, Int32 size)
--- End of inner exception stack trace ---
at System.Net.Sockets.NetworkStream.Write(Byte[] buffer, Int32 offset, Int32 size)
at .(TcpClient , String ) in C:\Users\steve\Documents\Visual Studio 2015\Projects\CumulusMX\CumulusMX\DavisStation.cs:line 660
at .() in C:\Users\steve\Documents\Visual Studio 2015\Projects\CumulusMX\CumulusMX\DavisStation.cs:line 552
at System.Threading.ThreadHelper.ThreadStart_Context(Object state)
at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
at System.Threading.ThreadHelper.ThreadStart()

Then everything stops with *** Data input appears to have stopped

Am I missing something obvious, what could be causing this, I assume the remote host is my Davis Vantage Pro2 with IP data logger itself?? MXDiag log attached.

Stephen

Re: Existing connection was forcibly closed by the remote ho

Posted: Wed 24 Feb 2016 7:25 am
by steve
stephenord wrote:I assume the remote host is my Davis Vantage Pro2 with IP data logger itself?
Yes, the logger is apparently closing the connection. Is Cumulus talking to the logger directly (via a router) or is there some other software or hardware involved?

Is your logger uploading to weatherlink.com?

Is there any other software communicating with the logger at the same time as MX?

Re: Existing connection was forcibly closed by the remote ho

Posted: Wed 24 Feb 2016 8:00 am
by stephenord
Is Cumulus talking to the logger directly (via a router) or is there some other software or hardware involved?
Connected directly, nothing else involved.
Is your logger uploading to weatherlink.com?
Ah, yes, I had forgotten all about that, I'm pretty sure it does. I will turn that off tonight and give it another go.

Thanks!

Stephen

Re: Existing connection was forcibly closed by the remote ho

Posted: Wed 24 Feb 2016 8:04 am
by steve
Do you have a 'periodic disconnect' set to allow for the uploads to weatherlink.com? You could try setting that, or if you already have it set, try adjusting the disconnect period.

Re: Existing connection was forcibly closed by the remote ho

Posted: Mon 29 Feb 2016 7:30 pm
by stephenord
Have turned off the Weatherlink option and all has been OK for a few days now. Thanks for the advice.

Stephen

Re: Existing connection was forcibly closed by the remote ho

Posted: Mon 29 Feb 2016 7:34 pm
by steve
There's a possibility that my check is wrong for whether the connection is re-established after the periodic disconnect (i.e. the station may not actually have finished uploading to weatherlink.com) - see this thread https://cumulus.hosiene.co.uk/viewtopic.php?f=27&t=14974

When I've changed my code, it may fix this problem.