DSheirer / sdrtrunk

A cross-platform java application for decoding, monitoring, recording and streaming trunked mobile and related radio protocols using Software Defined Radios (SDR). Website:
GNU General Public License v3.0
1.54k stars 251 forks source link

Heap leak #1863

Open amigan opened 6 months ago

amigan commented 6 months ago

sdrtrunk Version master-branch

Describe the bug I noticed on a couple occasions my two tuner raspberry pi 5 8GB would spin its fan up with occasional truncated calls, and suspected GC hell. I started using a JMX prometheus exporter to take a look. I haven't gotten it reproduce that specific behavior yet, but heap usage is definitely increasing over the long term. image image

The middle of those graphs was a restart. I am fairly certain the blip of concurrent GC before the restart was while the system was starting to truncate calls, but I'm no longer positive. I am continuing to leave this running to collect more data, but it definitely looks like the heap is growing? I'm not a java guy, so forgive me.

I am happy to take any dumps, or enable further profiling to assist in the effort to fix this.

To Reproduce Steps to reproduce the behavior:

  1. Monitor the RISCON P25 Phase 1 trunk system (10MHz allocation, 4x simulcast sites) with two RTL-SDRs.
  2. Leave it running.

Expected behavior Not fans spinning up with calls truncated.

Screenshots If applicable, add screenshots to help explain your problem.

Application Log If applicable, include either the full application log,or a snippet of the error logging.

Desktop (optional - complete the following information):

Additional context Streaming to rdio-scanner running on another machine and an icecast sink. This and icecast-kh are the sole workload of this system. The P25 system is moderately busy at times but not insane. I do think the problem manifests quicker during rare traffic spikes.

amigan commented 6 months ago

This is definitely happening right now. I have taken a heap dump hprof that I can furnish if necessary.

image image

I have attached a heap histogram. histogram.txt