Bug 190151 - OOM Killer don't kill processes when using tmpfs for /tmp and no swap
Summary: OOM Killer don't kill processes when using tmpfs for /tmp and no swap
Status: NEW
Alias: None
Product: Memory Management
Classification: Unclassified
Component: Other (show other bugs)
Hardware: x86-64 Linux
: P1 normal
Assignee: Andrew Morton
Depends on:
Blocks: 201673
  Show dependency tree
Reported: 2016-12-12 17:35 UTC by Илья Индиго
Modified: 2019-08-06 16:17 UTC (History)
2 users (show)

See Also:
Kernel Version: 4.8.13
Regression: No
Bisected commit-id:


Description Илья Индиго 2016-12-12 17:35:58 UTC
openSUSE Tumbleweed x86_64 | kernel 4.8.13-default | 4GB RAM

I have no swap, and I use tmpfs for /tmp with limit 2GB (half from 4GB).
Using commands archive "7z a -mx=9" or compilation "make -j4" cause a sharp intake of RAM, and sometimes, when I forget to unload heavy applications such as firefox, qBittorrent and skype, especially before "make -j4", my memory ends and OOM Killer It does not work automatically. Manual only (Alt+SysRq+F). Tmpfs share is less than 10%. And even if the lower limit of /tmp to a minimum, the auto it still does not work, manually only.

As far as I understand the situation, the contents of tmpfs is celebrated as the "cached". At the end of the contents of memory tmpfs displaced in the swap. If the swap is disabled or is not enough for the entire contents of a tmpfs, the OOM Killer will not work, as it sees that there are still cached and he is waiting for his ousting from memory.

In my opinion this is wrong behavior, because all system tmpfs swamping more than free the swap, will be subject to a similar problem.
Comment 1 Artem S. Tashkinov 2019-08-06 16:16:25 UTC
Related bug 201673.

Note You need to log in before you can comment on or make changes to this bug.