Describe the bug
Recently started seeing zombie processes. Usually one or more in a 24 to 36 hour period
To Reproduce
Steps to reproduce the behavior:
Expected behavior
No zombies
Screenshots
scottrus@storzilla:~$ ps aux | grep defunct
USER PID %CPU %MEM VSZ RSS TTY STAT START TIME COMMAND
bazarr 377 0.0 0.0 0 0 ? Z Apr26 1:06 [python3.8] <defunct>
scottrus 13425 0.0 0.0 13132 1092 pts/0 S+ 13:22 0:00 grep defunct
Software (please complete the following information):
Additional context
It's showed up in about the last week? I haven't been tracking it too closely.
If you force a full scan of hard disk, does it reproduce this issue?
I checked the Update all Episode Subtitles from disk setting and didn't see any zombie after running it. I also tried Update all Movie Subtitles from disk and didn't see any zombie processes either.
My guess would be released to the update from git but I cannot be sure. I guess that based on the intermittent nature of Timed Checks + Git Updates + my observations of this not being constant.
Thanks for testing. It's kind of hard to investigate without being able to reproduce it. Forcing an update after modifying a single file (like readme) could help reproduce on your side.
Sounds like a plan. I've created a PR :)
I meant for you to change a file locally so git would refresh it with head.
Okay, that caused it:
[development b5f119c9] update readme
1 file changed, 2 insertions(+)
scottrus@storzilla:/opt/bazarr$ tail -f /var/log/syslog | grep bazarr
Apr 27 19:10:53 storzilla bazarr[18535]: 2020-04-27 19:10:53,453 - root (7f671a7fc700) : INFO (check_update:56) - BAZARR Updated to latest version. Restart required. 1 file changed, 2 insertions(+)
Apr 27 19:10:58 storzilla bazarr[18535]: 2020-04-27 19:10:58,468 - root (7f673f53e700) : INFO (main:243) - Bazarr is being restarted...
Apr 27 19:11:02 storzilla bazarr[18535]: 2020-04-27 19:11:02,661 - root (7fbb811d8740) : INFO (main:2243) - BAZARR is started and waiting for request on http://0.0.0.0:6767/
^C
scottrus@storzilla:/opt/bazarr$ ps aux | grep bazarr
bazarr 18535 0.0 0.0 38960 9864 ? Ss 14:15 0:00 /usr/bin/python3.8 /opt/bazarr/bazarr.py
bazarr 18540 0.7 0.0 0 0 ? Z 14:15 2:12 [python3.8] <defunct>
bazarr 19829 5.3 0.5 1037748 80600 ? Sl 19:11 0:00 /usr/bin/python3.8 -u /opt/bazarr/bazarr/main.py
scottrus 19859 0.0 0.0 13132 1092 pts/0 S+ 19:11 0:00 grep bazarr
Recreate was straight forward:
Following that clue.. even easier, just hit the restart button in the UI
Should be all good now in dev branch! Please confirm.
The fix works! Thank you for the quick reply!