Message ID | a1b3c44d-fee8-1d8a-a61f-52332d04e938@ipfire.org |
---|---|
State | Rejected |
Headers |
Return-Path: <development-bounces@lists.ipfire.org> 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 4K6HMC1nwGz3wtR for <patchwork@web04.haj.ipfire.org>; Sun, 27 Feb 2022 21:53:27 +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 4K6HM96fDsz3vv; Sun, 27 Feb 2022 21:53:25 +0000 (UTC) Received: from mail02.haj.ipfire.org (localhost [127.0.0.1]) by mail02.haj.ipfire.org (Postfix) with ESMTP id 4K6HM95KrMz2yf0; Sun, 27 Feb 2022 21:53:25 +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 4K6HM73l0Lz2xbW for <development@lists.ipfire.org>; Sun, 27 Feb 2022 21:53:23 +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 4K6HM61wpxz3Yq for <development@lists.ipfire.org>; Sun, 27 Feb 2022 21:53:21 +0000 (UTC) DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003ed25519; t=1645998802; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=zwSnY/8gO8kdMtm0hR4Jeac3kKsk2CpiAVD5U2eS4GY=; b=2aS6A4NCcwQBxHpLC/o8Hx6okK/xoRhCsj1k/59GG8U+90us7dmQeuFu5tC0kYRv18g7oj Avuw5axKZxcmgyAA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003rsa; t=1645998802; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=zwSnY/8gO8kdMtm0hR4Jeac3kKsk2CpiAVD5U2eS4GY=; b=LdOU1Kg32P6SOcQ+WSJkOTulnt09vQ1q8pGVMIUDK0KEaf3LW+sPXE6k+KjKwShE0ieJS2 iNEv6GuoP+btv9RjdOl3QpbreGBmwPIBUvPwwRMP1uT6ykRrOq/nAyRgNOB0FsOsLh5gv1 +DCD/dt5EhbfV6MxQ7Qj5TRflRcL6Owfv874mT6wLH+gJ9l9XDu8TWiVz5EJxnE0WJDA4p zJ3bOGHyd+SiCae75D6iCAQAADqqtAgpcmibvlZ1pLkFcpHWL+g0wKFi8hpQY3j2pnX2Fz HhRJ+WMcD4BJAddW+htGBQeQObQZmJjXBmW52HV9ONbctd6kTIUOt4XSqNo63g== Message-ID: <a1b3c44d-fee8-1d8a-a61f-52332d04e938@ipfire.org> Date: Sun, 27 Feb 2022 21:53:14 +0000 MIME-Version: 1.0 Content-Language: en-US To: "IPFire: Development" <development@lists.ipfire.org> From: =?utf-8?q?Peter_M=C3=BCller?= <peter.mueller@ipfire.org> Subject: [PATCH] cleanfs: Clear /var/tmp on boot as well Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: development@lists.ipfire.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: IPFire development talk <development.lists.ipfire.org> List-Unsubscribe: <https://lists.ipfire.org/mailman/options/development>, <mailto:development-request@lists.ipfire.org?subject=unsubscribe> List-Archive: <http://lists.ipfire.org/pipermail/development/> List-Post: <mailto:development@lists.ipfire.org> List-Help: <mailto:development-request@lists.ipfire.org?subject=help> List-Subscribe: <https://lists.ipfire.org/mailman/listinfo/development>, <mailto:development-request@lists.ipfire.org?subject=subscribe> Errors-To: development-bounces@lists.ipfire.org Sender: "Development" <development-bounces@lists.ipfire.org> |
Series |
cleanfs: Clear /var/tmp on boot as well
|
|
Commit Message
Peter Müller
Feb. 27, 2022, 9:53 p.m. UTC
Similar to /tmp/, there is no reason to keep any leftovers in /var/tmp,
nor can any application expect content placed there to be persistent.
On several IPFire installations I have access to, this would remove
quite some clutter accumulated in /var/tmp over the years.
Signed-off-by: Peter Müller <peter.mueller@ipfire.org>
---
src/initscripts/system/cleanfs | 5 +++++
1 file changed, 5 insertions(+)
Comments
On 2/27/22 15:53, Peter Müller wrote: > Similar to /tmp/, there is no reason to keep any leftovers in /var/tmp, > nor can any application expect content placed there to be persistent. > > On several IPFire installations I have access to, this would remove > quite some clutter accumulated in /var/tmp over the years. > > Signed-off-by: Peter Müller <peter.mueller@ipfire.org> > --- > src/initscripts/system/cleanfs | 5 +++++ > 1 file changed, 5 insertions(+) > > diff --git a/src/initscripts/system/cleanfs b/src/initscripts/system/cleanfs > index d1cbb2547..f315682ce 100644 > --- a/src/initscripts/system/cleanfs > +++ b/src/initscripts/system/cleanfs > @@ -117,6 +117,11 @@ case "${1}" in > find . -xdev -mindepth 1 ! -name lost+found \ > -delete || failed=1 > > + boot_mesg -n " /var/tmp" ${NORMAL} > + cd /var/tmp && > + find . -xdev -mindepth 1 ! -name lost+found \ > + -delete || failed=1 > + > boot_mesg -n " /var/ipfire/dhcp" ${NORMAL} > cd /var/ipfire/dhcpc/ && find . -name "*.pid" -exec rm -f {} \; || failed=1 > cd /var/ipfire/dhcpc/ && find . -name "*.cache" -exec rm -f {} \; || failed=1 In that case, should ISO backups use a directory other than "/var/tmp/backupiso"? Thanks, Paul
Hello Peter, Hello List, I have to decline this patch because the IDS system currently stores the downloaded tarballs (which contains the rules of a provider) in that directory. Each time the ruleset is altered or updated, these tarballs will be decompressed and the required files are extracted from them. So cleaning up this directory, would remove the tarballs and currently breaks the entire IDS. We might have to think about keeping this tarballs or to move them to a different (better) location. Best regards, -Stefan > Similar to /tmp/, there is no reason to keep any leftovers in > /var/tmp, > nor can any application expect content placed there to be persistent. > > On several IPFire installations I have access to, this would remove > quite some clutter accumulated in /var/tmp over the years. > > Signed-off-by: Peter Müller <peter.mueller@ipfire.org> > --- > src/initscripts/system/cleanfs | 5 +++++ > 1 file changed, 5 insertions(+) > > diff --git a/src/initscripts/system/cleanfs > b/src/initscripts/system/cleanfs > index d1cbb2547..f315682ce 100644 > --- a/src/initscripts/system/cleanfs > +++ b/src/initscripts/system/cleanfs > @@ -117,6 +117,11 @@ case "${1}" in > find . -xdev -mindepth 1 ! -name lost+found \ > -delete || failed=1 > > + boot_mesg -n " /var/tmp" ${NORMAL} > + cd /var/tmp && > + find . -xdev -mindepth 1 ! -name lost+found \ > + -delete || failed=1 > + > boot_mesg -n " /var/ipfire/dhcp" ${NORMAL} > cd /var/ipfire/dhcpc/ && find . -name "*.pid" -exec > rm -f {} \; || failed=1 > cd /var/ipfire/dhcpc/ && find . -name "*.cache" -exec > rm -f {} \; || failed=1
Hello everyone, I agree with Paul and Stefan here. We should move things out of there first before we add this directory to the tidy up at boot time. Who would like to grab this and work on this? -Michael > On 28 Feb 2022, at 18:48, Stefan Schantl <stefan.schantl@ipfire.org> wrote: > > Hello Peter, Hello List, > > I have to decline this patch because the IDS system currently stores > the downloaded tarballs (which contains the rules of a provider) in > that directory. > > Each time the ruleset is altered or updated, these tarballs will be > decompressed and the required files are extracted from them. > > So cleaning up this directory, would remove the tarballs and currently > breaks the entire IDS. > > We might have to think about keeping this tarballs or to move them to a > different (better) location. > > Best regards, > > -Stefan >> Similar to /tmp/, there is no reason to keep any leftovers in >> /var/tmp, >> nor can any application expect content placed there to be persistent. >> >> On several IPFire installations I have access to, this would remove >> quite some clutter accumulated in /var/tmp over the years. >> >> Signed-off-by: Peter Müller <peter.mueller@ipfire.org> >> --- >> src/initscripts/system/cleanfs | 5 +++++ >> 1 file changed, 5 insertions(+) >> >> diff --git a/src/initscripts/system/cleanfs >> b/src/initscripts/system/cleanfs >> index d1cbb2547..f315682ce 100644 >> --- a/src/initscripts/system/cleanfs >> +++ b/src/initscripts/system/cleanfs >> @@ -117,6 +117,11 @@ case "${1}" in >> find . -xdev -mindepth 1 ! -name lost+found \ >> -delete || failed=1 >> >> + boot_mesg -n " /var/tmp" ${NORMAL} >> + cd /var/tmp && >> + find . -xdev -mindepth 1 ! -name lost+found \ >> + -delete || failed=1 >> + >> boot_mesg -n " /var/ipfire/dhcp" ${NORMAL} >> cd /var/ipfire/dhcpc/ && find . -name "*.pid" -exec >> rm -f {} \; || failed=1 >> cd /var/ipfire/dhcpc/ && find . -name "*.cache" -exec >> rm -f {} \; || failed=1 > >
diff --git a/src/initscripts/system/cleanfs b/src/initscripts/system/cleanfs index d1cbb2547..f315682ce 100644 --- a/src/initscripts/system/cleanfs +++ b/src/initscripts/system/cleanfs @@ -117,6 +117,11 @@ case "${1}" in find . -xdev -mindepth 1 ! -name lost+found \ -delete || failed=1 + boot_mesg -n " /var/tmp" ${NORMAL} + cd /var/tmp && + find . -xdev -mindepth 1 ! -name lost+found \ + -delete || failed=1 + boot_mesg -n " /var/ipfire/dhcp" ${NORMAL} cd /var/ipfire/dhcpc/ && find . -name "*.pid" -exec rm -f {} \; || failed=1 cd /var/ipfire/dhcpc/ && find . -name "*.cache" -exec rm -f {} \; || failed=1