From dd75235463a4e7ca2bc24d3219113456e6dab6f2 Mon Sep 17 00:00:00 2001 From: Simon Rettberg Date: Mon, 19 Mar 2018 11:30:15 +0100 Subject: [hardware-stats] Suppress local warnings about swap/tmp if flag-file is present --- .../data/opt/openslx/scripts/systemd-setup_dnbd3_proxy | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'core/modules/dnbd3-proxy-mode') diff --git a/core/modules/dnbd3-proxy-mode/data/opt/openslx/scripts/systemd-setup_dnbd3_proxy b/core/modules/dnbd3-proxy-mode/data/opt/openslx/scripts/systemd-setup_dnbd3_proxy index e1993f30..e19788bc 100755 --- a/core/modules/dnbd3-proxy-mode/data/opt/openslx/scripts/systemd-setup_dnbd3_proxy +++ b/core/modules/dnbd3-proxy-mode/data/opt/openslx/scripts/systemd-setup_dnbd3_proxy @@ -6,6 +6,9 @@ ERRLOG="/run/dnbd3-proxy.err" [ -s "$ERRLOG" ] && exit 0 # already ran and failed, don't do it again +# Log error to server and local file in /run. +# The main startup script will check whether this file is > 0 bytes +# and start in errormsg-mode. errormsg () { echo "$@" >> "$ERRLOG" slxlog -s -e "dnbd3-setup" "$@" @@ -40,6 +43,9 @@ else || ! [ "$(disksize "${DNBD3_BASE_DIR}")" -gt 12000 ]; then # no sane fallback possible errormsg "Neither a persistent part (ID45) nor /tmp (ID44) are available, or they are < 12GB" + else + # We're using /tmp, don't warn about low space + touch "/run/openslx/no-ram-warning" fi fi # now try to create the actual folder used by the server -- cgit v1.2.3-55-g7522