Codebase list atop / 2378c64
merge acct compat change from experimental Marc Haber 2 years ago
2 changed file(s) with 28 addition(s) and 13 deletion(s). Raw diff Collapse all Expand all
+0
-1
debian/compat less more
0 13
11 Author: Marc Haber <mh+debian-packages@zugschlus.de>
22 Forwarded: not yet
33 Last-Update: 2019-02-17
4 --- a/acctproc.c
5 +++ b/acctproc.c
4 Index: atop/acctproc.c
5 ===================================================================
6 --- atop.orig/acctproc.c
7 +++ atop/acctproc.c
68 @@ -158,7 +158,8 @@ struct pacctadm {
79 struct stat stat;
810 } pacctadm[] = {
1315 };
1416
1517 /*
16 --- a/atopacct.init
17 +++ b/atopacct.init
18 Index: atop/atopacct.init
19 ===================================================================
20 --- atop.orig/atopacct.init
21 +++ atop/atopacct.init
1822 @@ -29,7 +29,7 @@ case "$1" in
1923 start)
2024 # Check if process accounting already in use via psacct
2428 do
2529 if [ -f "$PACCTFILE" ] # file exists?
2630 then
27 --- a/man/atop.1
28 +++ b/man/atop.1
31 Index: atop/man/atop.1
32 ===================================================================
33 --- atop.orig/man/atop.1
34 +++ atop/man/atop.1
2935 @@ -162,11 +162,14 @@ daemon is not active,
3036 verifies if the process accounting mechanism has been switched on
3137 via the separate
4551 .PP
4652 .TP 4
4753 4.
48 --- a/psaccs_atop
49 +++ b/psaccs_atop
50 @@ -10,11 +10,12 @@
54 Index: atop/psaccs_atop
55 ===================================================================
56 --- atop.orig/psaccs_atop
57 +++ atop/psaccs_atop
58 @@ -10,11 +10,18 @@
5159 postrotate
5260 # check if process accounting is installed
5361 #
5967 - ACCTFILE=`awk '$2 == "{" {print $1}' /etc/logrotate.d/psacct`
6068 + # this is a heuristic that will fail once acct's cron.daily job changes
6169 + # please file a bug report against atop if you encounter this
62 + ACCTFILE=$(sed -n "/savelog[^\/]\+\(\/[[:alnum:]\/]\+\).*/{s//\1/;p;q;}" /etc/cron.daily/acct)
70 + then
71 + ACCTFILE="$(awk '$2 == "{" {print $1}' /etc/logrotate.d/psacct)"
72 + fi
73 + if grep -q 'savelog' /etc/cron.daily/acct
74 + then
75 + ACCTFILE="$(sed -n "/savelog[^\/]\+\(\/[[:alnum:]\/]\+\).*/{s//\1/;p;q;}" /etc/cron.daily/acct)"
76 + fi
6377
6478 if [ -f "$ACCTFILE" ]
6579 then
66 --- a/psaccu_atop
67 +++ b/psaccu_atop
80 Index: atop/psaccu_atop
81 ===================================================================
82 --- atop.orig/psaccu_atop
83 +++ atop/psaccu_atop
6884 @@ -8,7 +8,7 @@
6985 ifempty
7086 create 0600 root root