Page 2 of 3

Re: Realtime not updating

Posted: Thu 14 Apr 2016 3:48 pm
by Netsoul
Same problem here, log attached.
There's a "Mono.Security.Protocol.Tls.TlsException: Invalid certificate received from server. " error

Re: Realtime not updating

Posted: Thu 14 Apr 2016 4:09 pm
by steve
Netsoul wrote:There's a "Mono.Security.Protocol.Tls.TlsException: Invalid certificate received from server. " error
Please read the instructions. In particular, the part about downloading the trusted root certificates. A forum search would also have found this.

Re: Realtime not updating

Posted: Fri 15 Apr 2016 6:09 am
by vpokroglo
My next tought is that realtime stops updating at I think specific times. Today Stops at 6:26:59, Yesterday at almost same time, I remember at about 6:25.....

Re: Realtime not updating

Posted: Fri 15 Apr 2016 6:52 am
by Netsoul
steve wrote:
Netsoul wrote:There's a "Mono.Security.Protocol.Tls.TlsException: Invalid certificate received from server. " error
Please read the instructions. In particular, the part about downloading the trusted root certificates. A forum search would also have found this.
If you are talking about the "sudo mozroots --import --ask-remove" command, it was the second thing I've done. But the CumulusMX still stop working after some hours

Re: Realtime not updating

Posted: Fri 15 Apr 2016 7:11 am
by steve
Netsoul wrote:If you are talking about the "sudo mozroots --import --ask-remove" command, it was the second thing I've done.
Well you apparently hadn't done it (correctly) before the diags file you submitted.
But the CumulusMX still stop working after some hours
Turn on debug logging and data logging and submit the diags files when it stops working. Please give as much information as possible, e.g. what exactly do you mean by 'stops working'. Please start a new thread, it is very difficult to deal with two different people in the same thread. And you will probably have to do some investigating yourself, as vpokroglo is doing. Hundreds of people are using MX without this problem, so it is apparently something specific to your system, and hence it's very hard for me to say what the problem is unaided.

Re: Realtime not updating

Posted: Tue 19 Apr 2016 5:41 pm
by vpokroglo
I have some more finds about my problem. Cumulus realtime.txt stops updating two times a day at similar times.
Timestamps of last realtime.txt updates are:
17-4-2016 at 6:21:03
17-4-2016 at 19:12:02
18-4-2016 at 6:22:03
18-4-2016 at 19:13:09
19-4-2016 at 6:20:02
19-4-2016 at 19:14:04

There aren't any particularities in log files at this times.
And also CumulusMX is runing varying amounts of time - I mean that I do not reload Cumulus immediately after realtime.txt update hangs.

weird, weird, weird...

Re: Realtime not updating

Posted: Tue 19 Apr 2016 6:40 pm
by steve
It could be that something happens to cause the thread to hang - a problem with the ftp server or something. If the thread doesn't exit, the flag which says it is doing the realtime actions won't get unset, so it won't do anything on the next realtime timer tick.

You could try turning on ftp logging and restarting MX just before the time the problem normally happens, to see if anything unusual gets logged to the ftp log.

Re: Realtime not updating

Posted: Tue 19 Apr 2016 7:02 pm
by vpokroglo
So, if I understand correctly, the realtime doesn't even update localy on raspberry, if it is not corectly uploaded on server?

I thought that realtime.txt is first updated localy and then uploaded to ftp, so I haven't looked for ftp problems.

Am I correct?

Re: Realtime not updating

Posted: Tue 19 Apr 2016 7:06 pm
by steve
It gets updated next time if the ftp fails, but if something unusual happened during the ftp which caused the thread to hang and not exit, then it wouldn't get updated next time. This is pure speculation, I do not know what could happen to cause the thread to hang. It should either exit successfully or with some kind of error (connect timeout etc).

Re: Realtime not updating

Posted: Tue 19 Apr 2016 7:21 pm
by vpokroglo
OK. Thanks.
I will turn on ftp logging and then post log file here.
I am only a little confused why before on Cumulus 1.9 all was OK. Are there any differences between ftp-ing with Cumulus 1 on Windows and MX on Raspbian?

Re: Realtime not updating

Posted: Tue 19 Apr 2016 8:05 pm
by steve
The code in MX is all completely new. It's written in a completely different programming language. It uses a completely different runtime. It uses completely different third party components to handle ftp etc. It's running on a different operating system, with different system routines for file access etc.

And as I said, it is pure speculation that ftp has anything at all to do with the problem. It may be a problem on your system writing the realtime.txt file which causes the thread to exit unexpectedly. Or something else entirely.

Re: Realtime not updating

Posted: Thu 21 Apr 2016 5:02 am
by vpokroglo
There is some:
Testing connectivity using Socket.Poll()...
...
...

I attach ftp log.

Re: Realtime not updating

Posted: Thu 21 Apr 2016 11:45 am
by steve
At what time did realtime.txt stop being updated, and at what time did you capture this file? The last timestamp in the log is at 06:59:54. There is no indication of a problem at that time, it had just completed a realtime upload, but I don't know whether the file stops at that point because realtime updates stopped, or whether that was the time you captured the file. The timestamp does not correspond the other times that you posted previously.

Re: Realtime not updating

Posted: Thu 21 Apr 2016 5:42 pm
by vpokroglo
Thank You Steve.

Here is my ftplog. My realtime.txt stops updating at 21.04.16 19:16:02.

Re: Realtime not updating

Posted: Thu 21 Apr 2016 6:01 pm
by steve
There does appear to be some kind of communication problem with the ftp server, but I don't know why that would cause the updating of the realtime.txt file to stop. Perhaps the ftp component throws an exception which causes the thread to exit. You would normally expect the exception to be caught and logged by the outer level handler, though. I'll put some code in to catch any exceptions at a lower level, and make sure the 'updating' flag gets reset. It may not help, depending on what the problem actually is.