mxtommy / Kip

SignalK Instrument package
MIT License
77 stars 40 forks source link

KIP crashes from time to time #311

Open Techstyleuk opened 6 months ago

Techstyleuk commented 6 months ago

I have been running KIP on a new RPi 5 running Openplotter 4 Starting (12-29-2023), up to date. Signal K is version 2.5.0, Kip is 2.7. It is running in Chromium, and connected to the Signal K demo server.

I am running it 24/7 and each time I come back to it, perhaps every 6 hrs, Kip looks like this:

image
Sparhawk76 commented 5 months ago

I don't know if I am having the same issue or a different one. My use case is a bit different in that I run my OP3 install headless on a pi4-8gb. I access kip via Chrome on my Windows based mini-pc. I recently installed a second monitor connected to the mini-pc to have kip loaded all the time. My config is 4 measuring radial dials at the top monitoring my batteries and solar setup, below them an embedded grafana graph of my battery/solar info over time, then below that 3 more measuring radial dials, and a text field (this row for starlink stats), then on the bottom row I have a radial baseplate compass (rudder position), and beside that an embeded Pypilot Control tab. I have found that every morning since I set this up, I wake up and find the Chrome Aw Snap page. A bit of searching later and I found this bug report, which seemed current and similar issues.

godind commented 4 months ago

Hey guys. SK 2.7.2 is out and fixes a leak that caused repeated connection termination on the server side. It takes a while before the bug starts. Like 6-8h. It did not crash the server, just killed all clients.

I'm not sure this will resolve the issue, but it's possible that unknowingly, after 6-8h, KIP's connection is being repeatedly terminated causing an auto reconnect in KIP in the background.

Can someone test for me please? I dont't have a rip at hand.

Thanks

godind commented 4 months ago

eadless on a pi4-8gb. I access kip via Chrome on my Windows based mini-p

That means you get the problem in Chrome on windows, right? It's really hard to find this kind of problem! I'm rewriting lots of code and cleaning up all over. Have not found it yet. Next release will tell us more...

Techstyleuk commented 4 months ago

this is this morning, after update to latest KIP and SK and a reboot: image Chromium window did not crash

godind commented 4 months ago

Thanks for the report!

Have we won a small fight? Let see if need a few more fights to win the battle.

In any case, this issue has triggered a lot of rewrite and refactoring of KIP. All positive.

Techstyleuk commented 4 months ago

when I got home from work today, KIP had crashed, looking at the curves, I cannot see the point where it failed, but it was working 12hrs ago. image image

godind commented 4 months ago

So it doubles run time. Let's see if the next release improves things.

godind commented 4 months ago

@Techstyleuk still observing partial improvements?

I'm still working on to publish a refactored version that should improve ressource usage and close a few "potential" leaks, although minor.

Techstyleuk commented 4 months ago

I have been busy getting the boat ready to go back in the water, but I have this pi running in my Basement. I looked at it and it was frozen, I reset it and then will check it in 6 hrs or so.

Techstyleuk commented 3 months ago

it lasted about 12 hrs

godind commented 3 months ago

Hi all. Latest release v2.10.0 has a few fixes. It runs better with n my end. Can you report when you find time. Thanks!

Techstyleuk commented 3 months ago

I upgraded last night, It was still going strong after 12hrs. I had to shut it down for another reason, but will run it from later this morning and let you know in a couple of days

Techstyleuk commented 3 months ago

It did just crash after 13hrs. the funny thing is, this is my test environment running in my basement - Pi5, Openplotter V4 (Bookworm), latest KIP and SignalK. I was on my boat all weekend (55hrs) and never turned the system off - it is a Pi4, Openplotter 2, an earlier version of SignalK and a 2 week old version of KIP, upgraded just before launch 2 wks ago

godind commented 3 months ago

Thanks for the report. I can't pinpoint exactly where the problem is. I keep searching and plugging potential leaks. I double the time so far.

It is only reported with Chromium so far, not on all Chromium, os and hardware versions. It's related to Chromium install setting or builds and/or the way it manages the Java virtual machine memory cleanup and memory allocation.

godind commented 2 months ago

@Techstyleuk is KIP still running fine on pi4 and crashing on pi5 after 12+ hours?

Just keeping track.

Thanks

Techstyleuk commented 2 months ago

I had to turn my basement one off, but I will set it back up and check again after updating to the latest

Techstyleuk commented 2 months ago

after about 12hrs last night the whole thing was unresponsive. I will do an update and start testing again

Techstyleuk commented 2 months ago

after updating KIP to the latest and Signalk to the latest KIP ran for 11 hrs before needing to be refreshed due to being non responsive