Bug 110572 - app-laptop/i8kutils - i8k init.d script fails to daemonize i8kmon
|
Bug#:
110572
|
Product: Gentoo Linux
|
Version: unspecified
|
Platform: All
|
|
OS/Version: Linux
|
Status: RESOLVED
|
Severity: normal
|
Priority: P2
|
|
Resolution: FIXED
|
Assigned To: tester@gentoo.org
|
Reported By: xenos@xenos-1.net
|
|
Component: Applications
|
|
|
URL:
|
|
Summary: app-laptop/i8kutils - i8k init.d script fails to daemonize i8kmon
|
|
Keywords:
|
|
Status Whiteboard:
|
|
Opened: 2005-10-26 14:07 0000
|
When the /etc/init.d/i8k script runs to start i8kbuttons and i8kmon, i8kmon
fails to load.
Reproducible: Always
Steps to Reproduce:
1.emerge i8kutils
2./etc/init.d/i8k start
Actual Results:
* Starting i8kbuttons ...
[ ok ]
* Starting i8kmon ...
[ !! ]
Expected Results:
* Starting i8kbuttons ...
[ ok ]
* Starting i8kmon ...
[ ok ]
The solution seems simple enough. Could someone implement it?
30,31c30,31
< --make-pidfile --exec /usr/bin/i8kmon --background \
< -- -d ${NOAUTO:+-na} ${TIMEOUT:+-t $TIMEOUT}
---
> --make-pidfile --exec /usr/bin/tclsh --background \
> -- /usr/bin/i8kmon -d ${NOAUTO:+-na} ${TIMEOUT:+-t $TIMEOUT}
(In reply to comment #0)
> When the /etc/init.d/i8k script runs to start i8kbuttons and i8kmon, i8kmon
> fails to load.
>
> Reproducible: Always
> Steps to Reproduce:
> 1.emerge i8kutils
> 2./etc/init.d/i8k start
>
> Actual Results:
> * Starting i8kbuttons ...
> [ ok ]
> * Starting i8kmon ...
> [ !! ]
>
>
> Expected Results:
> * Starting i8kbuttons ...
> [ ok ]
> * Starting i8kmon ...
> [ ok ]
>
>
> The solution seems simple enough. Could someone implement it?
>
> 30,31c30,31
> < --make-pidfile --exec /usr/bin/i8kmon --background \
> < -- -d ${NOAUTO:+-na} ${TIMEOUT:+-t $TIMEOUT}
> ---
> > --make-pidfile --exec /usr/bin/tclsh --background \
> > -- /usr/bin/i8kmon -d ${NOAUTO:+-na} ${TIMEOUT:+-t
$TIMEOUT}
sorry, that's the diff between the broken /etc/init.d/i8k script and my working
version.
Conor
(In reply to comment #0)
> When the /etc/init.d/i8k script runs to start i8kbuttons and i8kmon, i8kmon
> fails to load.
> Reproducible: Always
> Steps to Reproduce:
> 1.emerge i8kutils
> 2./etc/init.d/i8k start
> Actual Results:
> * Starting
i8kbuttons ...
> [ ok ]
> * Starting
i8kmon ...
> [ !! ]
> Expected Results:
> * Starting
i8kbuttons ...
> [ ok ]
> * Starting
i8kmon ...
> [ ok ]
> The solution seems simple enough. Could someone implement it?
> 30,31c30,31
> < --make-pidfile --exec /usr/bin/i8kmon --background \
> < -- -d ${NOAUTO:+-na} ${TIMEOUT:+-t $TIMEOUT}
> ---
> > --make-pidfile --exec /usr/bin/tclsh --background \
> > -- /usr/bin/i8kmon -d ${NOAUTO:+-na} ${TIMEOUT:+-t
$TIMEOUT}
I would like to see this little problem fixed. What is involved in becoming a
package maintainer? Who do I need to speak with? It's not like this is a huge
bug.
(In reply to comment #2)
this last one works for me ....
taking over this package. I'll try to look at this problem this weekend
(In reply to comment #4)
> taking over this package. I'll try to look at this problem this weekend
>
Awesome! Thank you.
The tclsh patch works for me too, but I realized that the modified init script
needs tcl to be installed (wiped it out incidently by emerge -depclean).
So we should add a tcl dependency to the ebuild or find another approach to
solve the pid problem.
Regards, Sebastian
strange, the current script seems to work fine here.
Are you usin i8kutils 1.25? Which version of baselayout ?
I use the ~x86 baselayout (1.23.0_pre17-r2). Not sure if it works atm, have to
sort some things out first. Strange however is that /usr/bin/i8kmon is not
installed anymore by the ebuild. Is this intended?
OK. It's not installed any more by default as it depends on the USE flag "tk",
as it can be run in a GUI mode.
I am surprised that it hasn't been fixed yet, with such a simple patch to be
applied.
(In reply to comment #7)
> strange, the current script seems to work fine here.
> Are you usin i8kutils 1.25? Which version of baselayout ?
>
I'm using the following:
# emerge -p baselayout i8kutils
These are the packages that would be merged, in order:
Calculating dependencies... done!
[ebuild R ] sys-apps/baselayout-1.12.4-r6
[ebuild R ] app-laptop/i8kutils-1.25
To this day I still have to modify the init script to get i8kmon to daemonize.
Can we please add an einfo (or echo) at the end of the package build stating,
"i8kmon will only be built if the tk flag is enabled. Without i8kmon, the
daemon will not be able to control the fans (with /etc/i8kmon.conf)"?
Or, maybe have /etc/init.d/i8k* notify in syslog "i8kmon was not found, rebuild
i8kutils with the tk to build this binary"?
I have fixed the i8kmon within /etc/init.d/i8kmon. Before, it would always
fail starting because the i8kmon bin file forks to a tclsh process and does not
truely run in the background.
ebegin "Starting i8kmon"
start-stop-daemon -b --start --quiet --name "tclsh
/usr/bin/i8kmon" \
--exec /usr/bin/i8kmon \
-- -d ${NOAUTO:+-na} ${TIMEOUT:+-t $TIMEOUT}
eend $?
1) For some reason, "--background" was not fully working. So I switched to the
short term "-b" and moved it forward in the start-stop-daemon function.
2) Used "--name" to check for the process name instead. I belive I can do
--name "tclsh i8kmon" to more accurately filter /proc names, as you can see,
i've implemented it within the stop function
ebegin "Stopping i8kmon"
start-stop-daemon --stop --quiet --name "tclsh /usr/bin/i8kmon"
eend $?
1) Again, I removed the make-pid stuff as, again, i8kmon forks to another
process and I am just checking for the simple name of "tclsh /usr/bin/i8kmon".
Ok. retested. Ask if you want a diff.
after a long long time.. I've applied the fixes from comment #12