From patchwork Sat Jul 30 02:28:02 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: jon X-Patchwork-Id: 5793 Return-Path: Received: from mail01.ipfire.org (mail01.haj.ipfire.org [172.28.1.202]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384 client-signature ECDSA (P-384) client-digest SHA384) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by web04.haj.ipfire.org (Postfix) with ESMTPS id 4LvpGG570qz3x1v for ; Sat, 30 Jul 2022 02:28:22 +0000 (UTC) Received: from mail02.haj.ipfire.org (mail02.haj.ipfire.org [172.28.1.201]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) client-signature ECDSA (P-384)) (Client CN "mail02.haj.ipfire.org", Issuer "R3" (verified OK)) by mail01.ipfire.org (Postfix) with ESMTPS id 4LvpGD3sBwzf9; Sat, 30 Jul 2022 02:28:20 +0000 (UTC) Received: from mail02.haj.ipfire.org (localhost [127.0.0.1]) by mail02.haj.ipfire.org (Postfix) with ESMTP id 4LvpGD29kjz2ypj; Sat, 30 Jul 2022 02:28:20 +0000 (UTC) Received: from mail01.ipfire.org (mail01.haj.ipfire.org [172.28.1.202]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384 client-signature ECDSA (P-384) client-digest SHA384) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by mail02.haj.ipfire.org (Postfix) with ESMTPS id 4LvpGC0BNcz2yCy for ; Sat, 30 Jul 2022 02:28:19 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-384) server-digest SHA384) (No client certificate requested) by mail01.ipfire.org (Postfix) with ESMTPSA id 4LvpGB1KK7z9Q; Sat, 30 Jul 2022 02:28:18 +0000 (UTC) DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003ed25519; t=1659148098; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=ijQiL5yCgF/Axil1Ewkx6Bub1rku5qaF2gKEDlbYlK0=; b=aI4dgTpzvYRIYhzFP/LMc+LTdy7wHAnkCLm/oOuoNVqd90wc2bZ4xvQjiuxMxQN1Ba4kCB gOVX05jIh+iZ6ZBg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003rsa; t=1659148098; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=ijQiL5yCgF/Axil1Ewkx6Bub1rku5qaF2gKEDlbYlK0=; b=wqzV6m+XMCXrmnN+defPfNbUs3lb9p/eRqrLs6kOLjge13lhMeqHmQz100AOjcR4F9kkuL ds/3/hKql7Fhn14KHr87a12Yh+QSYHENT3U2/w3F28VrUjeS9CM9qOfMfYsQbYzyfunKmK 9QcVj/OmgdNEMVvFGVzghesHVniZSVwk+PxR8uJCW7lhjP6kwUt2okEFeHOUfYc/ZNKs+t IcNkRFw/WnjAok7GPXEpHpKnGqB46R777zjFuA7s7tkVOIqJPTKDbpcfIAwT+nnWYA2FGn usIjakAuXasygpj0X5j7Uqsv+EXFe4jswSYemiROXOwkuYUw0QnASUi26uoBOg== From: Jon Murphy To: development@lists.ipfire.org Subject: [PATCH] update.sh: clean out old collectd process statistics Date: Fri, 29 Jul 2022 21:28:02 -0500 Message-Id: <20220730022802.3653144-1-jon.murphy@ipfire.org> MIME-Version: 1.0 X-BeenThere: development@lists.ipfire.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: IPFire development talk List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: development-bounces@lists.ipfire.org Sender: "Development" - processes-mysqld - processes-snort - processes-rtorrent - processes-asterisk - processes-java - processes-spamd Signed-off-by: Jon Murphy --- config/rootfiles/core/170/update.sh | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/config/rootfiles/core/170/update.sh b/config/rootfiles/core/170/update.sh index cbac8572e..ec6c5ad09 100644 --- a/config/rootfiles/core/170/update.sh +++ b/config/rootfiles/core/170/update.sh @@ -170,6 +170,20 @@ sed -i /etc/collectd.conf \ -e "/LoadPlugin entropy/d" /etc/init.d/collectd restart +# Stop collectd Sevice +/etc/init.d/collectd stop + +# Cleanup old collectd statistics... +rm -rf /var/log/rrd/collectd/localhost/processes-mysqld +rm -rf /var/log/rrd/collectd/localhost/processes-snort +rm -rf /var/log/rrd/collectd/localhost/processes-rtorrent +rm -rf /var/log/rrd/collectd/localhost/processes-asterisk +rm -rf /var/log/rrd/collectd/localhost/processes-java +rm -rf /var/log/rrd/collectd/localhost/processes-spamd +# +# Start collectd +/etc/init.d/collectd start + # Start services /etc/init.d/rc.d/unbound start /etc/init.d/rc.d/suricata start