diff --git a/psacct-tmpfiles.conf b/psacct-tmpfiles.conf new file mode 100644 index 0000000..555f740 --- /dev/null +++ b/psacct-tmpfiles.conf @@ -0,0 +1,2 @@ +d /var/account 0755 root root - +f /var/account/pacct 0600 root root - diff --git a/psacct.spec b/psacct.spec index cacab60..eec7788 100644 --- a/psacct.spec +++ b/psacct.spec @@ -4,7 +4,7 @@ Summary: Utilities for monitoring process activities Name: psacct Version: 6.6.4 -Release: 25%{?dist} +Release: 26%{?dist} License: GPL-3.0-or-later URL: http://www.gnu.org/software/acct/ @@ -12,6 +12,7 @@ Source: ftp://ftp.gnu.org/pub/gnu/acct/acct-%{version}.tar.gz Source1: psacct.service Source2: psacct-logrotate.in Source3: accton-create +Source4: psacct-tmpfiles.conf Patch1: psacct-6.6.2-unnumberedsubsubsec.patch Patch2: psacct-6.6.1-SEGV-when-record-incomplete.patch @@ -81,6 +82,10 @@ install -m 755 %{SOURCE3} %{buildroot}%{_libexecdir}/psacct/ rm -f %{buildroot}%{_bindir}/last %{buildroot}%{_mandir}/man1/last.1* %endif +# tmpfiles.d configuration file for /var/account/pacct +mkdir -p %{buildroot}%{_tmpfilesdir} +install -m 0644 %{SOURCE4} %{buildroot}%{_tmpfilesdir}/psacct.conf + %post %systemd_post psacct.service @@ -122,9 +127,14 @@ touch /var/account/pacct && chmod 0600 /var/account/pacct %{_mandir}/man8/dump-acct.8* %{_mandir}/man8/dump-utmp.8* %{_infodir}/accounting.info.* +%{_tmpfilesdir}/psacct.conf %changelog +* Thu Sep 11 2025 Jan Rybar - 6.6.4-26 +- tmpfiles.d integration +- Resolves: RHEL-109879 + * Mon Jul 28 2025 Jan Rybar - 6.6.4-25 - post-rotate script aligned with systemd usage - Resolves: RHEL-62932