So rc-status shows atop is crashed.
+*atop-2.2 (25 Jun 2015) + + 25 Jun 2015; Lars Wendler <polynomial-c@gentoo.org> +atop-2.2.ebuild, + +files/atop-2.2-build.patch, +files/atop.rc-r1, +files/atopacct.rc: + Version bump. Added rewritten init script to fix bug #553246. + Let's hope this works. Feel free to reopen this bug in case it's not fixed for you.
I've emerged =sys-process/atop-2.2. It doesn't work. /etc/init.d/atop start freezes at first run. After Ctrl + C and running /etc/init.d/atop start one more time it shows: * Starting atop ... * start-stop-daemon: /etc/atop/atop.daily is already [ !! ] * ERROR: atop failed to start Adding --pidfile /var/run/atop.pid to start-stop-daemon call in start function of init script worked for 1.27_p3.
/etc/atop/atop.daily is the main process and will not daemonize itself. It seems we should add --background to start-stop-daemon, making it be: start-stop-daemon --start --pidfile ${pidfile} \ --exec /etc/atop/atop.daily --background
I confirm that --background option in init.d script solves this issue.
(In reply to Alexey Grebenschikov from comment #4) > I confirm that --background option in init.d script solves this issue. I confirm this too. But atop crashes sometimes now with /var/log/atop/daily.log: > existing file /var/log/atop/atop_20170701 has incompatible header
commit a1d059a3a560a5c93d3b9f6fe38d9789bf37b99c Author: Lars Wendler <polynomial-c@gentoo.org> Date: Wed Aug 2 14:55:16 2017 sys-process/atop: Fixed init script for atop-2.2 (bug #553246). Package-Manager: Portage-2.3.6, Repoman-2.3.3 Also fixed in atop-2.3.0