[mythtv-users] MythFrontend out of memory problem
Stephen Worthington
stephen_agent at jsw.gen.nz
Mon Apr 11 03:23:08 UTC 2022
On Sun, 10 Apr 2022 17:03:35 -0500, you wrote:
>Looking for a little help from the group:
>I'm running v31 fixes on Xubuntu v20.04 and have recently and only
>occasionally have the kernel kill mythfrontend.re for the reason of "Out of
>memory". It has happened 3 times in the last 4 weeks and a total of 6
>times since 2020. It's not a show-stopper, as it does recover after about
>5-10 minutes (I assume that's the amount of time it's using chewing up all
>the RAM). There isn't anything of interest in the mythfrontend.log file.
>Just normal stuff while watching a recording. This is a snippet from
>kern.log specifically about mythfrontend:
>
>Apr 9 22:00:03 MythTV kernel: [703811.529409] [ pid ] uid tgid
>total_vm rss pgtables_bytes swapents oom_score_adj name
>Apr 9 22:00:03 MythTV kernel: [703811.529507] [ 3635] 1000 3635
> 97165 1257 204800 987 0 xfce4-terminal
>Apr 9 22:00:03 MythTV kernel: [703811.529508] [ 3640] 1000 3640
>2751 196 61440 248 0 bash
>Apr 9 22:00:03 MythTV kernel: [703811.529510] [ 3753] 1000 3753
> 652 1 45056 30 0 mythfrontend
>Apr 9 22:00:03 MythTV kernel: [703811.529511] [ 3762] 1000 3762
> 3609880 1093884 12263424 307492 0 mythfrontend.re
>Apr 9 22:00:03 MythTV kernel: [703811.529512] [ 5513] 107 5513
>2648 37 53248 5 0 uuidd
>Apr 9 22:00:03 MythTV kernel: [703811.529513] [ 8712] 127 8712
> 652 0 40960 23 0 sh
>Apr 9 22:00:03 MythTV kernel: [703811.529514] [ 8713] 127 8713
>768613 462526 4624384 46665 0 mythcommflag
>
>Has anyone else seen this anomaly?
>
>Regards,
>
>Ken Emerson
There have been some memory leak problems with mythfrontend in the
past, but I have not seen any in v31 or v32. It is possible that you
have just accumulated too many recordings now. Mythfrontend is quite
memory hungry - it keeps the full recording list in RAM. So, how much
RAM does the system have? How much swap space is allocated? How much
swap space is mythfrontend.real using? How many recordings are there?
In general, these days I would recommend using at least 8 Gibytes of
RAM for systems where there are lots of recordings.
To find out what is using swap space, I use this script:
https://gist.github.com/samqiu/5954487
The pmap command will show the RAM usage of a process, but its output
is not easy to interpret. You can get all the available information
about a process from its /proc entry (under its PID number). Pmap
just copies information from some of those entries.
More information about the mythtv-users
mailing list