Plex not playing media periodically, but works after restart

I migrated from running Plex directly as a service on Ubuntu 16.04 to running on Docker under the same OS. This is because I was experimenting with Docker at the time, but after getting it working and installing many other containers, I decided to stick with it.

Within the past couple of weeks I noticed some videos not playing when I was at the gym. This was remote via Android. Then over the past couple of days I realized this was not related to only remote play, but local network.

I have found that rebooting will solve the problem temporarily, but it seems to creep back 2-3 times a day. Through various other searches I understand this could be related to database optimization, but even with optimization weekly, I still have the problem.

im getting the exact same issue. cant for the life of me work out why. all search results point to database optimisation or moving transcode folder but thats not the issue. its something else.

dont want to hijack your thread but ill post my logs up just incase someone has the answer it could help you too.

My issue are:
Plex works fine until no one is using it. then when you go back to stream the shows are movies just hang (spinning wheel)
If I reboot the container everything works perfectly again.
I can watch hours of content. but it plex server is left unused (idle) for and extended period of time it will need rebooting.

I seem to have fixed my issue thankfully. using this thread
had to add /tmp folder to my docker. All seem well now.
I saw the fault while skimming through my logs.
Hope it helps