[Matrix] UPnP videos fully download to RAM rather than stream causing mem leak & hang - Printable Version +- Kodi Community Forum (https://forum.kodi.tv) +-- Forum: Support (https://forum.kodi.tv/forumdisplay.php?fid=33) +--- Forum: General Support (https://forum.kodi.tv/forumdisplay.php?fid=111) +---- Forum: OS independent / Other (https://forum.kodi.tv/forumdisplay.php?fid=228) +---- Thread: [Matrix] UPnP videos fully download to RAM rather than stream causing mem leak & hang (/showthread.php?tid=364348) |
[Matrix] UPnP videos fully download to RAM rather than stream causing mem leak & hang - mmortal03 - 2021-09-06 I'm seeing a general UPnP video streaming bug on 19.x Matrix (and 20.x Master) on Windows and Android. This bug is not present on Leia 18.9. I've tested it on multiple machines. The description I'm providing is Windows-centric, but the problem also occurs on Android. After doing a fresh install of Kodi and enabling UPnP support in the settings, I simply add to the Videos section the generic "UPnP Media Servers (Auto Discover)" (upnp://) source. Then I browse the folder structure of the videos stored remotely on my NAS, select one of the videos (doesn't matter if it's an AVI, MKV, or MP4), and this begins a seemingly perpetual loading animation (spinning), and ever increasing memory use in Task Manager. When this happens, the video controls cannot be accessed to stop the video from loading, and no new videos can be loaded, so I must Exit Kodi. However, on clicking Exit in Kodi, Kodi will hang. If you use the X in Windowed mode in the right hand corner, Kodi will disappear but the process will not actually close, and the memory leak will continue to occur in the background until the process is forced to quit. What I believe is happening is that Kodi 19.x is for some reason trying to download the entire video file into RAM before it will play, rather than streaming it as was done previously. I can prove this with a relatively small sized MP4 video while monitoring the amount of RAM being taken up by the process until the video does finally load. A respectively large video file never loads, as it will just start to fill up a large amount of the system's memory and never fully download to RAM (which shouldn't be happening in the first place, these videos should be streaming). The problem here is not some problem with UPnP over my network, as it works just fine in Leia 18.9, as well as in VLC. And the problem is not the video format or bad video files, as all tested will play back fine locally in Matrix. Here is the debug log: https://paste.kodi.tv/eqodaharib.kodi RE: [Matrix] UPnP videos fully download to RAM rather than stream causing mem leak & hang - jjd-uk - 2021-09-07 Maybe @Montellese might have a moment to take a look at this. If you create an issue on github then it's more likely it will be looked it, more so if it easily replical. So if you can provide a step by step of how to replicate that will vastly improve the chances of it being looked at. RE: [Matrix] UPnP videos fully download to RAM rather than stream causing mem leak & hang - mmortal03 - 2021-09-07 (2021-09-07, 15:21)jjd-uk Wrote: Maybe @Montellese might have a moment to take a look at this. If you create an issue on github then it's more likely it will be looked it, more so if it easily replical. So if you can provide a step by step of how to replicate that will vastly improve the chances of it being looked at. Thanks. Unfortunately, after further testing, it looks like it's a regression in Kodi with only a particular DLNA server. This is going to make it a lot harder to reproduce. Unless the person debugging this has a QNAP NAS, it's probably not going to be reproducible for them. To be clear, QNAP has an official Media Streaming add-on (DLNA Media Server), which Kodi 18.9 functions properly with, while Kodi 19.x does not (this bug). However, if I use the alternative option on QNAP, Twonky DLNA Server, I can't reproduce the bug. Also, if I set up a Windows DLNA server (Windows Media Player Network Sharing service, with Media streaming options in Windows enabled), I can't reproduce the bug. So, something changed in Kodi 19.x that broke compatibility with the official QNAP DLNA Media Server, but that's it. I may just stick with Twonky, unless I run into further issues. |