Cache being emptied weirdly using Upnp server
#1
I play videos from my computer via Upnp server connection.
I am having playback buffering issues on Kodi on my Amazon Fire Stick. I tried to modify the cache settings. It's better but the problem still exists. Today I found something quite strange to me : when I pause the video, Kodi starts downloading video from my desktop as cache. However, when I resume the video, after 1 second, the cache gets empited instantly and Kodi starts caching again. Simply put, it clears all the cache every second. It just repeats caching over and over again. which means however big I preset my cache size, the video will always stutter. Is there a way to change how Kodi clears its cache ?
Reply
#2
(2022-09-17, 14:27)PeppaTom Wrote: I play videos from my computer via Upnp server connection.
I am having playback buffering issues on Kodi on my Amazon Fire Stick. I tried to modify the cache settings. It's better but the problem still exists. Today I found something quite strange to me : when I pause the video, Kodi starts downloading video from my desktop as cache. However, when I resume the video, after 1 second, the cache gets empited instantly and Kodi starts caching again. Simply put, it clears all the cache every second. It just repeats caching over and over again. which means however big I preset my cache size, the video will always stutter. Is there a way to change how Kodi clears its cache ?

I don't know what UPnP server you are using but are you sure it isn't transcoding playback on the fly ?   That will cause this type of behavior.  I use a UPnP server heavily for many clients and up to full bitrate UHD rips over Wifi and LAN.  I disable transcoding for Kodi clients because of the rich set of codecs already in Kodi.  I never touch any of the Kodi network buffering settings.  Unfortunately I don't use an Amazon fire stick but do run on Vero 4K+, Raspberry Pi, Windows machines and Roku devices.  If it is a transcoding issue, some UPnP servers support pretranscoding so it isn't being done on the fly, which provides smoother playback.  The solution I use has this capability and I use it with my Roku units. 

Another likely culprit is WiFi band and interference.  Are you using 2.4ghz Wi-Fi or 5ghz ?    The 2.4ghz band often has a lot of interference and isn't recommended for high bandwidth streaming.  I've done it with mixed and similar results to what you are seeing.  I did try playing with Kodi cache settings with UPnP streaming in the past.  I found it was an attempt to mask an underlying more fundamental problem.   . 


Jeff
Running with the Mezzmo Kodi addon.  The easier way to share your media with multiple Kodi clients.
Service.autostop , CBC Sports, Kodi Selective Cleaner and Mezzmo Kodi addon author.
Reply
#3
Thanks for you reply
I am using my computer as the uPnp Server and I am not sure about the transcoding thing. I don't think it's transcoded because it's 4K HDR Dolby Vision Dolby Atmos (all the fancy features a video can have) and when it's played on my Kodi it has all the features. 
About the bandwith part, I tested with Wifi6 the problem still exists. 
So I am thinking is there a way to change how Kodi empty the cache alongwith the playback ? or at least to know how it works
Reply
#4
(2022-09-17, 20:59)PeppaTom Wrote: Thanks for you reply
I am using my computer as the uPnp Server and I am not sure about the transcoding thing. I don't think it's transcoded because it's 4K HDR Dolby Vision Dolby Atmos (all the fancy features a video can have) and when it's played on my Kodi it has all the features. 
About the bandwith part, I tested with Wifi6 the problem still exists. 
So I am thinking is there a way to change how Kodi empty the cache alongwith the playback ? or at least to know how it works

Ok.  So by using your computer as a UPnP server, are you running Windows 10 or something else ?  Regardless, OS based UPnP servers tend to be limited in features so I concur that it is unlikely your UPnP server is doing transcoding but it would be good to know the actual UPnP server since things like HDR, Dolby Atmos and such are actually more likely to cause transcoding as the UPnP server tries to match to the client capabilities.  OS based UPnP servers also tend to be light on metadata and so your Kodi experience long term will be a bit limited.  But an OS based UPnP is an OK position to start with but it would be good to know more about your environment to see if other options might be better long term (i.e. # of clients, size of library etc..) .  An SMB vs. UPnP approach might be easier if this is a small environment..  I do support a Kodi UPnP addon for Kodi which might provide some improvement to your experience.

Is this the only file having this issue and other files in your library are fine or are you just starting out ?   This might actually be more of an issue with the Firestick itself not being able to keep up with the bitrate, HEVC, 4k and audio decoding on that hardware.  I believe the Team Kodi folks would want to see a debug log when the problem is occurring to be certain.  I don't have any problems with similar files in my setup but I am not running a Firestick.



Jeff
Running with the Mezzmo Kodi addon.  The easier way to share your media with multiple Kodi clients.
Service.autostop , CBC Sports, Kodi Selective Cleaner and Mezzmo Kodi addon author.
Reply
#5
Thanks for you reply
My firestick is capable of keeping up with the bitrate, it works fine when I play the movie from a flash drive. I tried Mezzmo addon but it won't load any of my videos even tho it can discover my Win10 uPnP server, which is quite weird.
Reply
#6
(2022-09-17, 23:30)PeppaTom Wrote: Thanks for you reply
My firestick is capable of keeping up with the bitrate, it works fine when I play the movie from a flash drive. I tried Mezzmo addon but it won't load any of my videos even tho it can discover my Win10 uPnP server, which is quite weird.

I'll need to know a bit more about the Mezzmo addon not loading any of your videos.  Can you tell me a little more about what is happening ?  Which version of Kodi are you running ?  Thanks for the info about playing from the flash drive.  Do other movies play and just this one is having the buffering issues or is it happening on many ?  I think the Team Kodi folks will need a debug log to help further with the playback buffering issue.

One other quick option you can try is downloading the Mezzmo UPnP server software, load it on your Win 10 machine, import a couple of problematic videos and see if they play.  We know the software works with Kodi in many other setups.  You'll also get all the features of the addon, which is far more than the stock Win10 UPnP version.  If you try that just ensure you set the device profile type to Kodi for your Firestick and disable transcoding in the device settings in Mezzmo.  I can help with that if you have issues.  One thing I should mention with Mezzmo is that there is a complete set of tuning parameters in the device profile files for each device type.  Mezzmo has tuned them for optimal performance with each device but changes can be made, which controls how the streams are delivered.  Also, the addon has a lookback option from 0-30 seconds where you can have it back up on a resume play.  This can be a handy feature for improving the resume playback experience.



Jeff
Running with the Mezzmo Kodi addon.  The easier way to share your media with multiple Kodi clients.
Service.autostop , CBC Sports, Kodi Selective Cleaner and Mezzmo Kodi addon author.
Reply
#7
Thanks for you reply.
After a few frustrating tries, I have finally located the issue : this behavior only occurs when the video file contains both Dolby Atmos and Dolby Vision features. If the video has either of them, it's fine. But this caching issue happens when it has both of the two features. I am new to this forum, could you please tell me how to report a bug ? (This sounds like a bug to me)
Reply
#8
Moreover, I am having an issue using Mezzmo on my computer as a UpnP server : some of my video files are recongnized as music files even tho I've changed the category to movie in properties settings.
Reply
#9
(2022-09-18, 11:35)PeppaTom Wrote: Thanks for you reply.
After a few frustrating tries, I have finally located the issue : this behavior only occurs when the video file contains both Dolby Atmos and Dolby Vision features. If the video has either of them, it's fine. But this caching issue happens when it has both of the two features. I am new to this forum, could you please tell me how to report a bug ? (This sounds like a bug to me)

Great detective work.  The fact that it plays locally via your SD card and not via UPnP actually points to a potential issue with the UPnP server vs. Kodi.  Here's a good link from a Team Kodi member on posting debug logs.  They might suggest you try an SMB approach or a different UPnP server to rule out an OS based UPnP server issue.  I just checked and my 4K rips with both play fine via Mezzmo UPnP.  What version of Kodi are you running ?  If you let me know a couple of the 4K UHD rips which don't work, I may have them and can try them myself.


Jeff
Running with the Mezzmo Kodi addon.  The easier way to share your media with multiple Kodi clients.
Service.autostop , CBC Sports, Kodi Selective Cleaner and Mezzmo Kodi addon author.
Reply
#10
May I know which client you are using ? I just downloaded some random video files that have both features and all of them have this weird caching behavior so I'm sure it has nothing to with specific titles. By the way do you know how to solve my Mezzmo library issue I just posted above ? Thanks !
Reply
#11
(2022-09-18, 14:50)PeppaTom Wrote: May I know which client you are using ? I just downloaded some random video files that have both features and all of them have this weird caching behavior so I'm sure it has nothing to with specific titles. By the way do you know how to solve my Mezzmo library issue I just posted above ? Thanks !

My clients are Vero 4K+, Raspberry Pi 4s, Intel NUC, Kodi on Win 10, Roku and web. All except Roku and web are running Kodi 18.9, 19.4 and 20 alpha 2 with the Mezzmo Kodi addon.  If you are running with a Mezzmo server now, the remove any Kodi caching configs in the advancedsettings.xml file and restart Kodi. Mezzmo will optimize the streams. I'll answer your question in a bit. I am away from my computer right now. In the interim look at Get Video Metadata for one which is wrong and manually get the data. I'll answer more in the other post.


Jeff
Running with the Mezzmo Kodi addon.  The easier way to share your media with multiple Kodi clients.
Service.autostop , CBC Sports, Kodi Selective Cleaner and Mezzmo Kodi addon author.
Reply

Logout Mark Read Team Forum Stats Members Help
Cache being emptied weirdly using Upnp server0