cpu load signalk on cerbo gx high
i am having a high cpu load for signalk node on my cerbo gx. I am trying to disable plugin per plugin, but cpu load stays high. it's on 2.5.0 - is there anyway how i can easily debug my cpu load per process inside signalk?
38 Replies
the SignalK is a very heavy application. It requires a lot of memory and CPU.
I've seen swap increase after a few days of work. There may be a memory leak.
for some reason it has been worse since i upgraded cerbo gx to firmware 3.20 which includes signalk 2.5. I upgraded manually signalk to newest version 2.7.1 but still high cpu load.
What do you have connected to sk? How busy is it, how many deltas per sec?
As you may have done disabling all plugins may rule out one problem area
Another would be discarding some not relevant pgns that have high update rate
Bottom of Data Fiddler gives you access to pgns that sources produce. We could add stats there to help in analysis…
i have nmea ve can enabled
ais has high update rate, let me play with that. i might just disable whole nmea2000 to test
i am trying to filter out address 43 which is my ais in the data connection settings. But it doesnt get filtered out. Am i forgettnig anything?
![No description](https://cdn.answeroverflow.com/1227631670589657188/image.png)
![No description](https://cdn.answeroverflow.com/1227631670866214962/image.png)
Devices on the n2k bus is a more likely culprit than ais
What id do you see in the data item list, 43 or canname?
Ah your ais is n2k…nevertheless
Have you restarted? Can’t remember if that is required for changes to take effect
Ah thanks, it was the restart likely. The data is not showing anymore in databrowser, so that works. But the CPU load is not decreasing, maybe because signalk is still processing the input to make the decision to even filter it
If I disable n2k as a whole, I go from 50% cpu load (which is 80% at 1 core almost if i look per core1 vs core2) to 6%. So it's definitely somewhere in n2k. Wondering what is the best option to tune that down. How to best 'disregard' pgns? should i use the filter? doesnt look like the load is going down though
delta / s is around 60 without ais and 100 with
OK, if i filter out ALL n2k addresses (until delta is 0 / s), the cpu load will still stay the same - only slidely reduce, so that hypotheses that filtering wont reduce cpu load seems to be true. If i disable n2k though it goes drastically down which is good, but then also critical n2k like speed and wind are not available unfortunately
I can just shut down the hardware of the AIS, but I like the functionality to be a station for marinetraffic.com, hmmmm. Should i consider going with a bigger capacity in terms of hardware? Like adding raspberry pi next to cerbo where the raspberry pi then can be dedicated for signalk?
is something else on the cerbo suffering from sk using cpu?
something we can do is that you capture some of your data by turning data logging on for the n2k connection (and then turn logging off!) and share the log file with me, i can take a look at the actual input data
signalk itself is suffering from the cpu usage. it gets very very slow, like opening node red 1 minute instead of 5 seconds
will turn on data logging!
ok turned it on for couple of minutes, now used: find /data/conf/signalk -type f -name "*.log"
which one should i choose? 😉 just the raw one? /data/conf/signalk/skserver-raw_2024-04-10T18.log
the raw log. will have a look over the weekend
i guess it's the AIS, lot of vessels around. Boat is in Amsterdam and I think it already catches there 100s of boats
you see lot of entries with PGN 129038 alone already
around 1200 AIS targets tracked per minute, see here: https://www.marinetraffic.com/ais/details/stations/35031 (it's turned off now but you can see historical data)
The SignalK by itself works fine with about 800 AIS targets. I checked. However through the NMEA 0183.
The FreeboardSK isn't.
have you tried disabling node-RED?
Yes, although not much change. Even when all plugins disabled, the cpu load is still high. THe plugin that reduce cpu load the most is the udp nmea 1803 one