Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 239748 - >=sys-process/acct-6.3.5-r1 - /usr/sbin/accton is not available at boot time
Summary: >=sys-process/acct-6.3.5-r1 - /usr/sbin/accton is not available at boot time
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Gentoo's Team for Core System packages
URL:
Whiteboard:
Keywords:
: 256081 (view as bug list)
Depends on:
Blocks:
 
Reported: 2008-10-04 22:59 UTC by Xake
Modified: 2024-03-01 18:37 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Xake 2008-10-04 22:59:16 UTC
I have bootchart merged with USE="acct".
During boot I get a message from bootchart saying it can't find /sbin/accton.
This is becouse sys-process/acct installs accton to /usr/sbin.

The problem is that if I should change bootchart to use /usr/sbin/accton, it still will not work since my /usr resides on another partition and is not avaible during initial boottime.

So is this something that should be fixed package-wise (which it should either way so bootchart finds accton without modifications), or is this something I have to make a workaround for becouse my /usr does not resides on the / partition?
Comment 1 Ryan VanderPlas 2008-10-05 09:48:08 UTC
A workaround if you want it:  boot up with a live disk.  Mount / and /usr.  copy over accton to /.  unmount /usr.  Create a folder named /usr/sbin in the / partition.  copy accton from / to /usr/sbin/.

Before you mount /usr, the files you created will be there.  After you mount /usr, those files will 'hide' under the mount.  However, the file can never by auto updated and this isn't a good long term strategy.  Its just something to get you going if you have to have it.
Comment 2 Xake 2008-10-05 14:18:58 UTC
...or I copy the /usr/sbin files to /sbin, that way I do not have to alter bootchartd. But still the same problems, which should be fixed.
Comment 3 Jeroen Roovers (RETIRED) gentoo-dev 2008-10-05 18:55:56 UTC
(In reply to comment #1)
> A workaround if you want it:  boot up with a live disk.  Mount / and /usr. 
> copy over accton to /.  unmount /usr.  Create a folder named /usr/sbin in the /
> partition.  copy accton from / to /usr/sbin/.

This isn't a support forum. Please refrain from handing out (bad) advice.
Comment 4 SpanKY gentoo-dev 2008-10-05 21:39:18 UTC
bootchart shouldnt hardcode paths to binaries
Comment 5 Alistair Bush (RETIRED) gentoo-dev 2008-10-06 08:20:46 UTC
(In reply to comment #4)
> bootchart shouldnt hardcode paths to binaries
> 

So this is clear for everyone.

The issue isn't that bootchart hardcodes paths as seen by

PATH="/sbin:/bin:/usr/sbin:/usr/bin:$PATH"

the issue is that acct isn't available due to /usr/sbin not having been mounted.

Now Xake, does bootchart work with <sys-process/acct-6.3.5-r1?
Comment 6 Xake 2008-10-06 20:36:22 UTC
I tried to emerge that version when I checked around before filing this bug, but it complained about a file collision so I did not feel comfortable going through with it. I think the file was "last", but I can confirm if you like.
Comment 7 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2008-10-06 23:37:50 UTC
6.3.5-r3 moves it back to /sbin, with a symlink at the old spot. Fix bootchart now.

Other distros:
Fedora, RHEL, Mandriva, Connectiva: /sbin
Debian, Ubuntu: /usr/sbin
Slackware: /usr/sbin in old versions, can't check new ones atm

And really, bootchart needs to stop using acct and go use audit instead.
Comment 8 Jeroen Roovers (RETIRED) gentoo-dev 2009-01-24 02:07:02 UTC
*** Bug 256081 has been marked as a duplicate of this bug. ***
Comment 9 Jeroen Roovers (RETIRED) gentoo-dev 2009-01-24 02:12:42 UTC
(In reply to comment #7)
> 6.3.5-r3 moves it back to /sbin, with a symlink at the old spot. Fix bootchart
> now.

There's nothing to fix, really. The shell script /sbin/bootchartd sets PATH properly:

PATH="/sbin:/bin:/usr/sbin:/usr/bin:$PATH"

 and calls `accton' without a path prefixed:
# grep -n accton /sbin/bootchartd
63:             accton kernel_pacct
161:            accton
Comment 10 Xake 2009-08-21 17:00:46 UTC
This seems to work for me now. Is it properly fixed and should be closed, or is there something else left to be done?
Comment 11 Markus Gothe 2009-10-10 03:28:25 UTC
Well, I relased acct 6.5.1 last month so a new ebuild would do. ;)

//Markus Gothe

(In reply to comment #10)
> This seems to work for me now. Is it properly fixed and should be closed, or is
> there something else left to be done?
> 
Comment 12 Jeroen Roovers (RETIRED) gentoo-dev 2010-01-26 05:35:55 UTC
Er, this seems to be fixed three times now. Stabilisation in bug #302285. :)
Comment 13 Larry the Git Cow gentoo-dev 2024-03-01 07:55:39 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=038e31c37d6e59768ae7abf5083559a0950c308f

commit 038e31c37d6e59768ae7abf5083559a0950c308f
Author:     Sam James <sam@gentoo.org>
AuthorDate: 2024-03-01 06:08:16 +0000
Commit:     Sam James <sam@gentoo.org>
CommitDate: 2024-03-01 07:54:39 +0000

    sys-process/acct: update EAPI 7 -> 8, fix _F_S=3 crash, fix startup
    
    * EAPI 8
    * Fix crash with _FORTIFY_SOURCE=3 (bug #925419)
    * Use tmpfiles to create /var/accounts/pacct which fixes startup/use on new installs
    * Drop ancient workaround (bug #239748)
    
    Bug: https://bugs.gentoo.org/239748
    Signed-off-by: Sam James <sam@gentoo.org>

 sys-process/acct/acct-6.6.4-r4.ebuild              | 55 ++++++++++++++++++++++
 ...-fortify-source-3-sprintf-buffer-overflow.patch | 15 ++++++
 sys-process/acct/files/acct.tmpfiles               |  1 +
 3 files changed, 71 insertions(+)