From 5b816e350c52fe37e081c24bbfa2391ff7abab5f Mon Sep 17 00:00:00 2001 From: jbohack Date: Tue, 12 Nov 2024 17:15:25 -0500 Subject: [PATCH] Update manual installation documentation for `bjorn.service` This update introduces the below PR into the manual install: https://github.com/infinition/Bjorn/pull/27 --- README.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/README.md b/README.md index 9c4ff93..3c137f7 100644 --- a/README.md +++ b/README.md @@ -541,6 +541,9 @@ StandardError=inherit Restart=always User=root +# Check open files and restart if it reached the limit (ulimit -n buffer of 1000) +ExecStartPost=/bin/bash -c 'FILE_LIMIT=$(ulimit -n); THRESHOLD=$(( FILE_LIMIT - 1000 )); while :; do TOTAL_OPEN_FILES=$(lsof | wc -l); if [ "$TOTAL_OPEN_FILES" -ge "$THRESHOLD> + [Install] WantedBy=multi-user.target ```