PMS Plex Docker - Constant disk activities

Reduced HDD activity. That’s coming from two things:

  • The Plex log itself wouldn’t log the request to /identity any more every 5 seconds.
  • Docker itself would stop writing to hostconfig.json and config.v2.json every 5 seconds.

Yes, the first can be solved by disabling Plex debug logs. And yes, the second is actually a Docker bug. But changing the dockerfile would solve both things immediately for all users. In constrast disabling debug logs would need a config change from everyone. And waiting for the Docker bugfix might take a long time.

I guess Docker would take longer to notice if Plex doesn’t respond any more. But I don’t know what Docker does with that information. Maybe it automatically restarts the container?

I’d even question if the healthcheck is needed at all. I’ve read that the linuxserver/plex image doesn’t do a healthcheck at all. (I’ll have to switch to that if Plex doesn’t change its official image.)

For me personally the reason is reduced noise. I can sadly hear my NAS when it accesses its disk (I only have a small flat and no other place to put it). That isn’t a problem when I actually use it (e.g. play a movie with Plex), but is annoying at night when it’s otherwise very quiet.

Synology Package Center queries all apps every 5 seconds by calling the start-stop-status shell script. This behavior is very common with NAS systems (appliances).

My office, which doubles as my bedroom, is 110 sq ft (10 sq meters).
At my desk, I can reach out and touch both NAS boxes.

I am not bothered by it because I can barely hear it - Both are on the bakers rack at a level below the table which is my desk plus I have a carpeted floor

I fully understand and appreciate that if you have a room, which is spartanly decorated, any noise whatsoever is going to seem 10x louder than it really is. (Empty spaces amplify all noises)

I think noise abatement / mitigation is the solution here. One person won’t be able to get the entire community to move.

What are some noise mitigation techniques available?
There are mats available.

Software wise, Write a shell script to go edit the value and be done with it.

My shell scripts which update my containers make all their tweaks with every update.

If the Synology Package Center does this then it doesn’t matter for me (maybe it doesn’t read/write from/to the disk for its check?). When I stop the Plex container my NAS is extremely quiet (aside from maybe a disk access every few minutes - which is absolutely no problem compared to a disk access every 5 seconds). And that’s even with 3 other Docker images running. Only the Plex image causes the constant disk access.

I have as much noise mitigation as possible for my NAS. It is inside a closet (not good for temperature, I know - there is a small ventilation opening). It even stands on foam material so that the noise doesn’t expand to the floor or closet sides.
To be honest I just had the bad luck to buy a loud disk (a Seagate IronWolf). I also run a NAS at my parent’s place with a WD Red and it’s way quieter.

How could a shell script help in my case?

I understand that my reason for wanting the change is not important for the Plex team. But this issue with Plex Docker constant disk access is widespread and different people have different reasons why it’s bad. Some examples:
https://forums.plex.tv/t/pms-docker-unraid-is-constantly-writing-to-its-docker-home-library/419895
https://www.reddit.com/r/PleX/comments/bece3f/official_plex_docker_on_unraid_server_is/
https://www.reddit.com/r/unRAID/comments/gw4k6x/plex_help_it_keeps_writing/
https://www.reddit.com/r/unRAID/comments/beaavt/plex_docker_is_constantly_writing_to_my_cache_ssd/
https://www.reddit.com/r/unRAID/comments/ea85gc/high_disk_writes_with_official_plex_docker_in/
https://www.reddit.com/r/unRAID/comments/j7vw4z/constantly_writing_to_ssd_cache_drive_through/
https://forums.unraid.net/bug-reports/stable-releases/683-unnecessary-overwriting-of-json-files-in-dockerimg-every-5-seconds-r1079/
https://forums.unraid.net/topic/84858-loop2-dockerimg-writing-a-lot-to-the-cache/
https://forums.unraid.net/topic/92444-docker-containers-keeps-writing-to-hostconfigjson-and-configv2json/

Hi Cremor, i went through the same back and forth. Believe me, it is easier to switch to linuxserver image than to have plex fix a faulty behaviour.

I can totally feel your pain, for me it was an noise, power and durability issue. Disabling healtcheck is a one-liner for the plex team.
Unfortunately I have this with other containers as well. Cant believe docker did still not fix that. Tried to file a bug for docker but wasnt even able to locate their bug filing system…

2 Likes

Just out of curiosity: so the problem is that the container health check uses curl to query http://localhost:32400/identity and redirects the response to the null device (=no disc activity) instead to the console (=also no disc activity). So if this request should be the issue, then whatever generates the response for /identity would be responsible (in plex), shouldn’t it?

Hi Kopfpilot,

no, the curl is probably not the problem. I thought this in the beginning. Its a docker issue. Docker writes the configs on every health check result and not just on status changes. If there is a healthy every 5s, docker would write both config new every 5s. Very annoying. Some containers you can switch of healthcheck, that helpes. But it does not work for the plex container. Switching to linuxserver image does the trick though

To be exact it is both. Plex writes two log lines for every health check in its own log file. And Docker rewrites some of its files for every health check.

So both parties would need to fix/change something if the healthcheck should stay but not access the disk anymore.
Of course the easy way for Plex would be to just remove that one healthcheck line from the Dockerfile. That way both problems are immediately gone.

1 Like

I finished to use the Linuxserver Docker Image…was the simplest solution. Sad that Plex never mangaged to fix that

Does switching to Linuxserver Docker Image use the same appdata or do you have to move the database/files?

I’ve been waiting a long time for this to get fixed but there seems to be some finger pointing.

Is this the one that’s working for you?
plex
linuxserver’s Repository

PS I have raid1 SSD cache pool so no noise problems but this activity is supposed to be extremely detrimental to their health+time.

yes, you can use the same appdata. switching is seamless

1 Like

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.