Hi,

thanks for helping with atop.

On Thu, Nov 11, 2021 at 04:09:52PM +0800, Fei Li wrote:
> 1st. Should activate atopacctd before activating the atop daemon.

Looks right. Will accept after trying.

> * 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.

How can I verify this? What was the method you did to see that atop
starts earlier than atopacctd? What are the symptoms of the wrong start
oder?

> * 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]

What is wrong here, and what would be correct behavior?

> 2nd. Load atop.default file into the package to make it take effect

The 2.6.0-2 package in sid and bullseye do install a file to
/etc/default/atop. This file is different from the atop.default in the
upstream tarball. Debian does set the -R by default.

Please explain why you think the packaging does things wrong.

Greetings
Marc

-- 
-----------------------------------------------------------------------------
Marc Haber         | "I don't trust Computers. They | Mailadresse im Header
Leimen, Germany    |  lose things."    Winona Ryder | Fon: *49 6224 1600402
Nordisch by Nature |  How to make an American Quilt | Fax: *49 6224 1600421

Reply via email to