1nohang(1) General Commands Manual nohang(1)
2
3
4
6 nohang - A highly configurable OOM preventer
7
8
10 nohang [OPTION]...
11
12
14 Nohang is a highly configurable daemon for Linux which is able to cor‐
15 rectly prevent out of memory (OOM) and keep system responsiveness in
16 low memory conditions.
17
18
20 For basic usage:
21
22 - Linux 3.14+ (since MemAvailable appeared in /proc/meminfo)
23
24 - Python 3.3+ (not tested with previous)
25
26 To show GUI notifications:
27
28 - Notification server (most of desktop environments use their own
29 implementations)
30
31 - libnotify (Fedora, Arch Linux) or libnotify-bin (Debian
32 GNU/Linux, Ubuntu)
33
34 - sudo if nohang started with UID=0
35
36 To use PSI:
37
38 - Linux 4.20+
39
40
42 -h, --help show this help message and exit
43
44 -v, --version print version
45
46 -p, --print-proc-table
47 print table of processes with their badness
48 values
49
50 -c CONFIG, --config CONFIG
51 path to the config file, default values:
52 ./nohang.conf, /etc/nohang/nohang.conf
53
54 -cc CONFIG, --check-config CONFIG
55 check and print config
56
57
59 The program can be configured by editing the config file.
60
61 The configuration includes the following sections:
62
63 - Memory levels to respond to as an OOM threat
64
65 - Response on PSI memory metrics
66
67 - The frequency of checking the level of available memory (and CPU
68 usage)
69
70 - The prevention of killing innocent victims
71
72 - Impact on the badness of processes via matching their names, cmd‐
73 lines and UIDs with regular expressions
74
75 - The execution of a specific command or sending any signal instead
76 of sending the SIGTERM signal
77
78 - GUI notifications:
79 - notifications of corrective actions taken
80 - low memory warnings
81
82 - Verbosity
83
84 - Misc
85
86 Just read the description of the parameters and edit the values.
87
88 Please restart nohang to apply the changes.
89
90 Default path to the config after installing is /etc/nohang/nohang.conf.
91
92
94 To view the latest entries in the log (for systemd users):
95
96 $ sudo journalctl -eu nohang
97
98 See also man journalctl.
99
100 You can also enable separate_log in the config to logging in
101 /var/log/nohang/nohang.log.
102
103
105 https://github.com/hakavlad/nohang
106
107
108
109 nohang(1)