]> granicus.if.org Git - ejabberd/commitdiff
Set disk_almost_full_threshold to 99%
authorEvgeniy Khramtsov <ekhramtsov@process-one.net>
Tue, 19 Dec 2017 06:55:19 +0000 (09:55 +0300)
committerEvgeniy Khramtsov <ekhramtsov@process-one.net>
Tue, 19 Dec 2017 06:55:19 +0000 (09:55 +0300)
src/ejabberd_system_monitor.erl

index 926cea552a7f3e62f1b2f1e22444cc974538c39d..7787b34aba5e176f0c1b13028571f732017453de 100644 (file)
@@ -42,6 +42,8 @@
 %%-include("logger.hrl").
 
 -define(CHECK_INTERVAL, timer:seconds(30)).
+-define(DISK_FULL_THRES, 0.99).
+
 -record(state, {tref :: reference(),
                mref :: reference()}).
 -record(proc_stat, {qlen :: non_neg_integer(),
@@ -65,6 +67,8 @@ start() ->
     application:set_env(os_mon, start_cpu_sup, false),
     application:set_env(os_mon, start_os_sup, false),
     application:set_env(os_mon, start_memsup, true),
+    application:set_env(os_mon, start_disksup, true),
+    application:set_env(os_mon, disk_almost_full_threshold, ?DISK_FULL_THRES),
     ejabberd:start_app(os_mon).
 
 excluded_apps() ->