Your message dated Mon, 10 Jan 2022 09:18:32 +0000
with message-id <[email protected]>
and subject line Bug#999448: fixed in atop 2.7.0-1
has caused the Debian Bug report #999448,
regarding atop: Two fixes for debian/rules: activate atopacctd before
activating atop, load atop.default into pkg
to be marked as done.
This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.
(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)
--
999448: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=999448
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: atop
Version: 2.6.0-2
Severity: normal
Dear Maintainer,
Thanks for your supporting and maintaining debian atop package, we
have been running atop as a quite useful monitoring tool in bytedance
for years. But recenly, when trying to make a new package based on
2.6.0-2, we find two unexpected behaviors in debian/rules file
(although these two have been there for long times, we just notice
them recently :) ).
1st. Should activate atopacctd before activating the atop daemon.
* Backgournd
Reading from atop mannual, we know that there are four ways to get
access to the terminated process accounting records:
- environment variable ATOPACCT
- the atopacctd daemon (the preferred way)
- the separate psacct package
- using the file /var/cache/atop.d/atop.acct
* Problem
By reading the source code, to use the preferred way: atopacct daemon,
we should ensure that atopacctd starts before atop. But the current
mechanism is that atop starts earlier than atopacctd.
Although atop's daily restarting mechanism (instead, atopacct will not
restart daily until being restarted deliberately) makes atop reads
from /run/pacct_shadow.d/*.paf again, we still think this should be
repaired.
* Reproduce
Install atop package, get atop and atopacct's pid, check their fds:
# ps aux |grep atop
root 473309 4.7 0.0 37056 15792 ? S<Ls 15:50 0:00
/usr/bin/atop -w /var/log/atop/atop_20211111
root 473377 0.0 0.0 12012 128 ? S< 15:50 0:00
/usr/sbin/atopacctd
root 473742 0.0 0.0 18084 1024 pts/0 S+ 15:50 0:00 grep atop
# ls -l /proc/473309/fd
total 0
lr-x------ 1 root root 64 Nov 11 15:50 0 -> /dev/null
l-wx------ 1 root root 64 Nov 11 15:50 1 -> /var/log/atop/daily.log
l-wx------ 1 root root 64 Nov 11 15:50 2 -> /var/log/atop/daily.log
lr-x------ 1 root root 64 Nov 11 15:50 3 -> /var/cache/atop.d/atop.acct
lrwx------ 1 root root 64 Nov 11 15:50 4 -> socket:[503893125]
l-wx------ 1 root root 64 Nov 11 15:50 5 -> /var/log/atop/atop_20211111
lrwx------ 1 root root 64 Nov 11 15:50 6 -> socket:[503893413]
# ls -l /proc/473377/fd
total 0
lr-x------ 1 root root 64 Nov 11 15:50 0 -> /run/pacct_source
l-wx------ 1 root root 64 Nov 11 15:50 1 -> /run/pacct_shadow.d/0000000000.paf
lrwx------ 1 root root 64 Nov 11 15:50 2 -> socket:[503865811]
l-wx------ 1 root root 64 Nov 11 15:50 3 -> /run/pacct_shadow.d/current
lrwx------ 1 root root 64 Nov 11 15:50 4 -> socket:[503860044]
lrwx------ 1 root root 64 Nov 11 15:50 5 -> socket:[503860045]
* Fix
See the patch in the end :)
2nd. Load atop.default file into the package to make it take effect
* Background
We find that atop.default is not loaded into atop package, but this
file is sometimes used to read environment file in systemd service.
* Fix
See the patch in the end :)
We have tried to fix these two issues via a patch as follows:
**********************The beginning of patch*********************
>From 5f962975fa340e75a9a75e94deb8fd8a618ee918 Mon Sep 17 00:00:00 2001
From: Fei Li <[email protected]>
Date: Wed, 10 Nov 2021 20:45:45 +0800
Subject: [PATCH] Fix debian/rules
Two fixes for debian/rules:
- Activate atopacctd before activating the atop daemon, so that atop
can read exited process data from /run/pacct_shadow.d/*.paf instead
of /var/cache/atop.d/atop.acct once installed.
- Load atop.default file into the package to make it take effect.
Signed-off-by: Fei Li <[email protected]>
Co-authored-by: Teng Hu <[email protected]>
---
debian/rules | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/debian/rules b/debian/rules
index 7990f9d..8f3e091 100755
--- a/debian/rules
+++ b/debian/rules
@@ -5,18 +5,19 @@
override_dh_auto_clean:
dh_auto_clean
- rm -f debian/atop.service debian/atopacct.service debian/atop.init
debian/atopacct.init
+ rm -f debian/atop.service debian/atop.default debian/atopacct.service
debian/atop.init debian/atopacct.init
rm -f atop atopsar
override_dh_installinit:
- dh_installinit --name=atop
dh_installinit --name=atopacct
+ dh_installinit --name=atop
override_dh_auto_install:
dh_auto_install
make sysvinstall DESTDIR=$(shell pwd)/debian/atop
make systemdinstall DESTDIR=$(shell pwd)/debian/atop
cp atop.service debian/atop.service
+ cp atop.default debian/atop.default
cp atopacct.service debian/atopacct.service
cp atop.init debian/atop.init
cp atopacct.init debian/atopacct.init
--
2.20.1
**********************The end of patch**********************
-- System Information:
Debian Release: 10.5
Architecture: amd64 (x86_64)
Kernel: Linux 5.4
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
Versions of packages atop depends on:
ii libc6 2.28-10
ii libglib2.0-0 2.58.3-2+deb10u2
ii libncurses6 6.1+20181013-2+deb10u2
ii libtinfo6 6.1+20181013-2+deb10u2
ii lsb-base 10.2019051400
ii zlib1g 1:1.2.11.dfsg-1
Versions of packages atop recommends:
ii cron [cron-daemon] 3.0pl1-134+deb10u1
atop suggests no packages.
-- no debconf information
--- End Message ---
--- Begin Message ---
Source: atop
Source-Version: 2.7.0-1
Done: Marc Haber <[email protected]>
We believe that the bug you reported is fixed in the latest version of
atop, which is due to be installed in the Debian FTP archive.
A summary of the changes between this version and the previous one is
attached.
Thank you for reporting the bug, which will now be closed. If you
have further comments please address them to [email protected],
and the maintainer will reopen the bug report if appropriate.
Debian distribution maintenance software
pp.
Marc Haber <[email protected]> (supplier of updated atop package)
(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing [email protected])
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256
Format: 1.8
Date: Sun, 09 Jan 2022 23:27:42 +0100
Source: atop
Architecture: source
Version: 2.7.0-1
Distribution: unstable
Urgency: medium
Maintainer: Marc Haber <[email protected]>
Changed-By: Marc Haber <[email protected]>
Closes: 999448
Changes:
atop (2.7.0-1) unstable; urgency=medium
.
* new upstream version 2.7.0
* better handling of accounting data
* psacc[su]_atop is no longer necessary
* make systemdinstall is now make install
* remove rotation helper logrotate snippets
* don't start atop-rotate.service, it is invoked by timer
* remove helper log file imitations in postinst
* Janitor fixes:
* use debhelper-compat
* remove obsolete maintscript entry
* use secure URI in Homepage field
* trim trailing whitespace
* add basic salsa-ci. Thanks to Otto Kekäläinen
* add Upstream metadata
* create /etc/default/atop as patch from Upstreams file.
Thanks to Fei Li (Closes: #999448)
* remove conflicts on non-existing acct.service
* add first trivial autopkgtest
* debian/copyright:
* clarify license for files without explicit license
* fix double file name
* fix a typo
* update year for debian packagin
Checksums-Sha1:
c3d8c75172d8cf5749b4890ed87c47361d3fa889 1891 atop_2.7.0-1.dsc
17abcd6256ff2d2a9797d4b1dcaad0f19fc534fb 258880 atop_2.7.0.orig.tar.gz
7140b7650e900aeeeec5cd6a6f2efaf5d6799383 14500 atop_2.7.0-1.debian.tar.xz
0ef486bc36ef065c7f18cd6b39572a55f2a5fc41 5730 atop_2.7.0-1_source.buildinfo
Checksums-Sha256:
b2f641f473d2ff7b559667d5dab102abe19ee320488352e9e92628b3a4913b16 1891
atop_2.7.0-1.dsc
a606705aaca940a6d44d67c886529a75db98fd88140f743eb0aaebb184c38af7 258880
atop_2.7.0.orig.tar.gz
03fd4db97b7b37b9fd0dd6c669a4825566f0151504d2377c9799e4a9bb0735c5 14500
atop_2.7.0-1.debian.tar.xz
a511f0d7a7d2668a1bcbcfb8771fe080f0091bb39eab551a266236c90e79fcee 5730
atop_2.7.0-1_source.buildinfo
Files:
b66819fa4b330b5402df06b47c99000d 1891 admin optional atop_2.7.0-1.dsc
d7b9871f12ea0fb3fa6a9c80da072bc8 258880 admin optional atop_2.7.0.orig.tar.gz
cf1ed5ea346235b1e8730018a6989594 14500 admin optional
atop_2.7.0-1.debian.tar.xz
6a2cc5fcb8656bf72d50328a745ec580 5730 admin optional
atop_2.7.0-1_source.buildinfo
-----BEGIN PGP SIGNATURE-----
iQIzBAEBCAAdFiEE6QL5UJ/L0pcuNEbjj3cgEwEyBEIFAmHb9J4ACgkQj3cgEwEy
BEIHKBAA1+xZ040sIIy931i8t6zFzJHdJ8ZScBCwcxoodM8gyftiNOmD6SEIXqfF
bZMCjnSJZmjzrVbKrVJwNr5gIbfIjFbQzhMc6u4IBT2jXxIieNif75EEgjBmXzOz
gCP1lKgNhHUDKex0dbZLVnXsseG1autW/QRcIx+HdF2hxfvAoziEqA7KSPR2luJb
gUWaz3BtvSzPAfwqCq6KbJT7dPe1DhX+edi8IMdM/jVdtiGa6PGPB+Hm3+T4KtfB
6KFpjQAxIjo7lWv0C03SWI3k2uI9PVya1QDT5XfGpKVblWlkU/BdNAjlinPYKt9L
fMFawQYZ/Xx9r/Yl+Kx1l6Sis3BMVjHwgoexqg68nbhaEEU/Vjw45SR0bPKH4maC
z1w279WaSjGH+yhyFc/wk7CirD1l2GKPVeV482El7Na731Ef60gMgEWwBSVjjSLx
wqTsAR4nkGJ5eQapJXX9jt3+R4vM4f0EtNoTf9+7GWUSg4fiJmx/Z9o9kvYchuTM
/M+PUPZjAdOYVsxMKYE70tEi4oWssrFcGUIcPRAaf+GKTy33Kuc6aWf6Cqcg3bZ4
cBLBEB5BT8WIaf/40eT/PxnafgT2KTw3yLeg475UNcuqKT3Q/0JdOmGRFzEbpjEQ
KRRaXDV1phQSK+TCt9GK7Q9jibXKaiwrCwCRgB9U+7lV+Sg0qJc=
=gha8
-----END PGP SIGNATURE-----
--- End Message ---