From 31cf9fb59e2237d522cb521368de4e2aee757f9b Mon Sep 17 00:00:00 2001 From: Matthew Sevey Date: Wed, 24 Nov 2021 14:13:26 -0500 Subject: [PATCH 1/5] Disable load check until we have a process of actively addressing it --- setup-scripts/health-checker.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/setup-scripts/health-checker.py b/setup-scripts/health-checker.py index 7c5e9d94..738e8c2c 100755 --- a/setup-scripts/health-checker.py +++ b/setup-scripts/health-checker.py @@ -43,7 +43,9 @@ setup() async def run_checks(): print("Running Skynet portal health checks") try: - await check_load_average() + # Disabling load check until we have metrics solution and process to + # better address + # await check_load_average() await check_disk() await check_health() await check_alerts() From d1cbbb4ebb74561cda147cda49038ab37f7ddabb Mon Sep 17 00:00:00 2001 From: PJ Date: Wed, 1 Dec 2021 10:38:25 +0100 Subject: [PATCH 2/5] Add min_free param to proxy_cache_path directive --- docker/nginx/nginx.conf | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker/nginx/nginx.conf b/docker/nginx/nginx.conf index a6883cb8..c8da6b0f 100644 --- a/docker/nginx/nginx.conf +++ b/docker/nginx/nginx.conf @@ -70,7 +70,7 @@ http { proxy_http_version 1.1; # proxy cache definition - proxy_cache_path /data/nginx/cache levels=1:2 keys_zone=skynet:10m max_size=50g inactive=48h use_temp_path=off; + proxy_cache_path /data/nginx/cache levels=1:2 keys_zone=skynet:10m max_size=50g min_free=100g inactive=48h use_temp_path=off; # this runs before forking out nginx worker processes init_by_lua_block { From 92d33e3176eaa44725602256205bc4dec908e6ec Mon Sep 17 00:00:00 2001 From: PJ Date: Wed, 1 Dec 2021 10:46:58 +0100 Subject: [PATCH 3/5] Add changelog --- changelog/items/other/min-free-param.md | 1 + 1 file changed, 1 insertion(+) create mode 100644 changelog/items/other/min-free-param.md diff --git a/changelog/items/other/min-free-param.md b/changelog/items/other/min-free-param.md new file mode 100644 index 00000000..0a6239f3 --- /dev/null +++ b/changelog/items/other/min-free-param.md @@ -0,0 +1 @@ +- Set `min_free` parameter on the `proxy_cache_path` directive to `100g` From 3e17c1a9ee264f9854254dbcb17aac896056ddad Mon Sep 17 00:00:00 2001 From: Matthew Sevey Date: Wed, 1 Dec 2021 12:07:15 -0500 Subject: [PATCH 4/5] remove ping instead of disable --- setup-scripts/health-checker.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/setup-scripts/health-checker.py b/setup-scripts/health-checker.py index d0654b58..a8f83a32 100755 --- a/setup-scripts/health-checker.py +++ b/setup-scripts/health-checker.py @@ -46,9 +46,7 @@ setup() async def run_checks(): print("Running Skynet portal health checks") try: - # Disabling load check until we have metrics solution and process to - # better address - # await check_load_average() + await check_load_average() await check_disk() await check_health() await check_alerts() @@ -74,7 +72,9 @@ async def check_load_average(): load_av = re.match(pattern, uptime_string).group(1) if float(load_av) > 10: message = "High system load detected in uptime output: {}".format(uptime_string) - await send_msg(message, force_notify=True) + # Disabling pings until we have metrics solution and process to better + # address + await send_msg(message, force_notify=False) # check_disk checks the amount of free space on the /home partition and issues From c45b9c41bd2fc3b402fe9f3b88f814d3366b2946 Mon Sep 17 00:00:00 2001 From: Matthew Sevey Date: Wed, 1 Dec 2021 14:16:46 -0500 Subject: [PATCH 5/5] format --- setup-scripts/health-checker.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/setup-scripts/health-checker.py b/setup-scripts/health-checker.py index a8f83a32..b66459a8 100755 --- a/setup-scripts/health-checker.py +++ b/setup-scripts/health-checker.py @@ -111,7 +111,9 @@ async def check_disk(): # dump disk usage script_dir = os.path.dirname(os.path.realpath(sys.argv[0])) - os.popen(script_dir + "/disk-usage-dump.sh " + script_dir + "/" + DISK_USAGE_DUMP_LOG) + os.popen( + script_dir + "/disk-usage-dump.sh " + script_dir + "/" + DISK_USAGE_DUMP_LOG + ) inspect = os.popen("docker inspect sia").read().strip() inspect_json = json.loads(inspect)