Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 434698 - dev-libs/libcgroup: init.d script is not POSIX compliant
Summary: dev-libs/libcgroup: init.d script is not POSIX compliant
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Unspecified (show other bugs)
Hardware: All Linux
: Normal enhancement (vote)
Assignee: Anthony Basile
Depends on:
Reported: 2012-09-11 08:04 UTC by Natanael Copa
Modified: 2016-01-10 21:16 UTC (History)
0 users

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

untested patch (cgconfig.initd.patch,3.25 KB, patch)
2012-09-11 08:42 UTC, Natanael Copa
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Natanael Copa 2012-09-11 08:04:46 UTC
The cgconfig.initd script uses bash arrays which requires bash. The init.d scripts should be POSIX compliant.
Comment 1 Natanael Copa 2012-09-11 08:42:28 UTC
Created attachment 323478 [details, diff]
untested patch

Should behave *exactly* the same as current init.d (eg break if you have a lvm device called /dev/vg0/lv_macgroup or similar) while still being POSIX compliant.

Completely untested.
Comment 2 Alexander Vershilov (RETIRED) gentoo-dev 2013-05-28 21:08:55 UTC
There are a list of a problems in these init scripts and it's logic should be reviewed because openrc handles main cgroups itself. I'll try to post questions in the nearest future.
Comment 3 Mark 2014-01-23 01:42:43 UTC
Minor fix, while in cgred init script can you change:

start() {
	local options="${NODAEMON} ${LOG}"
	if [[ -n "${LOG_FILE}" ]]; then
		options="${options} --log-file=${LOG_FILE}"      


start() {
	local options="${NODAEMON} ${LOG}"
	if [[ -n "${LOG_FILE}" ]]; then
		options="${options} --logfile=${LOG_FILE}"      

I fixed this for myself but it must not be much of an issue since no one else has written a bug.  I know I am not supposed to do it this way.
Comment 4 Anthony Basile gentoo-dev 2016-01-10 21:16:14 UTC
the init scripts have been completely redone with libcgroup-0.41-r3.ebuild and should be POSIX.  Please reopen if you see anything that isn't.