Bug #5314
closedMemory leak in sat>ip server with scrambled channels
100%
Description
Hi,
I'm using 1 TT-4650CI DVBC tuner with a cccam connection to my local oscam server for descrambling. When using the sat>ip server for streaming, memory starts running full at about 1% every 45 seconds. When the memory usage is about 50%, it leads to situation where the connection to the tuner is lost. In my case after 50 minutes.
2018-11-03 14:54:45.166 [WARNING] TS: TN/314MHz/EUROSPORT HD: H264 #4301 Continuity counter error (total 1)
2018-11-03 14:54:45.166 [WARNING] TS: TN/314MHz/EUROSPORT HD: TELETEXT #4303 Continuity counter error (total 1)
2018-11-03 14:54:45.184 [WARNING] TS: TN/314MHz/EUROSPORT HD: MPEG2AUDIO @ #4302 Continuity counter error (total 1)
2018-11-03 14:54:46.080 [WARNING] subscription: 0002: service instance is bad, reason: No access
2018-11-03 14:54:48.080 [ NOTICE] subscription : 0002: No input source available for subscription "SAT>IP Slave/TN/314MHz/EUROSPORT HD" to service "TN/314MHz/EUROSPORT HD" in mux "314MHz in TN"
I tried with DVBViewer and VLC for streaming via RTSP, both have same effect.
When using http for streaming, the issue doesn't appear and tvheadend memory usage stays under 1%
The strange thing is that:
- When I start tvheadend memory usage is like 1%
- I let it run for a few minutes and then start a sat>ip connection with DVBViewer or VLC to a scrambled channel
- I see the memory going up slowly. About 1% every 45 seconds.
- If the RTSP connection is stopped, memory usage goes back to normal.
The issue does not appear when streaming FTA channels or when streaming scrambled channels over http. The issue is present both with a CI module and cccam connection to oscam. I tried multiple distro's ubuntu 14.04 16.04 18.04 the issue is present on all kernels.
The valgrind log eats 100% cpu and some kind of overflow occurs which kills the satip connection.
2018-11-03 20:11:09.755 [WARNING] TS: TN/314MHz/EUROSPORT HD: H264 #4301 Continuity counter error (total 1)
2018-11-03 20:11:14.896 [WARNING] linuxdvb: Silicon Labs Si2168 #0 : DVB-C #0 - read() EOVERFLOW
2018-11-03 20:11:21.510 [WARNING] TS: TN/314MHz/EUROSPORT HD: H264 #4301 Continuity counter error (total 3)
2018-11-03 20:11:21.532 [WARNING] TS: TN/314MHz/EUROSPORT HD: TELETEXT #4303 Continuity counter error (total 1)
2018-11-03 20:11:21.532 [WARNING] TS: TN/314MHz/EUROSPORT HD: MPEG2AUDIO #4302 Continuity counter error (total 1)
2018-11-03 20:11:27.349 [WARNING] linuxdvb: Silicon Labs Si2168 #0 : DVB-C #0 - read() EOVERFLOW
2018-11-03 20:11:32.770 [WARNING] linuxdvb: Silicon Labs Si2168 #0 : DVB-C #0 - read() EOVERFLOW
2018-11-03 20 :11:35.499 [WARNING] linuxdvb: Silicon Labs Si2168 #0 : DVB-C #0 - read() EOVERFLOW
2018-11-03 20:11:37.700 [ INFO] subscription: 0002: "SAT>IP Slave/TN/314MHz/EUROSPORT HD" unsubscribing, client="SAT>IP Slave/TN/314MHz/EUROSPORT HD"
2018-11-03 20:11:39.268 [WARNING] linuxdvb: Silicon Labs Si2168 #0 : DVB-C #0 - read() EOVERFLOW
2018-11-03 20:11:40.023 [ INFO] subscription: 0001: "SAT>IP" unsubscribing, hostname="192.168.1.2"
I really don't have reception problems because I can easily stream an FTA channel without any issues.. also during my valgrind command.
FTA channels only use about 80% of CPU when running the valgrind command.
So, somewhere still a problem with satip-server and descrambling?
The valgrind log seems to have some usefull information already. If you need more logs, please let me know.
Files