From 7ad2503323b62f91733de31d6206affb70017d34 Mon Sep 17 00:00:00 2001 From: Alexey Avramov Date: Wed, 12 Dec 2018 16:17:50 +0900 Subject: [PATCH] fix conf --- nohang.conf | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/nohang.conf b/nohang.conf index 816ea86..0d5174b 100644 --- a/nohang.conf +++ b/nohang.conf @@ -128,7 +128,7 @@ oom_score_adj_max = 30 See https://en.wikipedia.org/wiki/Regular_expression and https://en.wikipedia.org/wiki/Perl_Compatible_Regular_Expressions - Enabling this option slows down the search for the victim + Enabling this options slows down the search for the victim because the names, cmdlines or UIDs of all processes (except init and kthreads) are compared with the specified regex patterns (in fact slowing down is caused by @@ -137,6 +137,9 @@ oom_score_adj_max = 30 Use script `oom-sort` from nohang package to view names, cmdlines and UIDs of processes. + + 4.1 Matching process names with RE patterns + Valid values are True and False. regex_matching = False @@ -147,8 +150,6 @@ regex_matching = False RE patterns must be valid and must not be empty! - Matching process names with RE patterns - prefer_regex = ^()$ Valid values are floating-point numbers from the range [1; 1000]. @@ -168,7 +169,7 @@ avoid_regex = ^(Xorg|sshd)$ avoid_factor = 3 - Matching cmdlines with RE patterns + 4.2 Matching cmdlines with RE patterns A good option that allows fine adjustment. @@ -182,7 +183,7 @@ avoid_re_cmdline = ^/usr/lib/virtualbox avoid_cmd_factor = 3 - Matching UIDs with RE patterns + 4.3 Matching UIDs with RE patterns The most slow option @@ -194,6 +195,11 @@ prefer_uid_factor = 1 avoid_re_uid = ^()$ avoid_uid_factor = 1 + Note that you can control badness also via systemd units + via OOMScoreAdjust, see + https://www.freedesktop.org/software/systemd/man/systemd.exec.html#OOMScoreAdjust= + + ##################################################################### 5. The execution of a specific command instead of sending the