# rpm -qf /usr/sbin/htt iiimf-server-11.4-41 From a default boot into runlevel 5, do: # telinit 3 after a few seconds you're left with two htt daemons; the latter is eating CPU, continually spawning a new child which dies because it can't bind to port 9010 10967 ? S 0:00 /usr/sbin/htt 10968 ? S 0:00 \_ htt_server -nodaemon 11175 ? R 0:00 /usr/sbin/htt 15648 ? R 0:00 \_ htt_server -nodaemon # strace -f -e clone,bind -p 11175 --- SIGCHLD (Child exited) @ 0 (0) --- clone(Process 18988 attached child_stack=0, flags=CLONE_CHILD_CLEARTID|CLONE_CHILD_SETTID|SIGCHLD, child_tidptr=0xf70d68c8) = 18988 Process 11175 suspended [pid 18988] bind(3, {sa_family=AF_INET, sin_port=htons(9010), sin_addr=inet_addr("127.0.0.1")}, 16) = -1 EADDRINUSE (Address already in use) Process 11175 resumed Process 18988 detached --- SIGCHLD (Child exited) @ 0 (0) --- clone(Process 18989 attached child_stack=0, flags=CLONE_CHILD_CLEARTID|CLONE_CHILD_SETTID|SIGCHLD, child_tidptr=0xf70d68c8) = 18989 Process 11175 suspended [pid 18989] bind(3, {sa_family=AF_INET, sin_port=htons(9010), sin_addr=inet_addr("127.0.0.1")}, 16) = -1 EADDRINUSE (Address already in use) Process 11175 resumed Process 18989 detached --- SIGCHLD (Child exited) @ 0 (0) ---
The service design itself needs work, but for now the problem can be avoided by fixing the /etc/init.d/IIim script. Unfortunately in the course of investigating this bug, I realized that it causes 100% CPU usage and total failure of htt's functionality in non-obvious way. =( Setting FC2BLOCKER and rebuilding now, but it is up to Elliot if he would allow this update into FC2 final. If not then this should go out in the first batch of FC2 updates immediately upon release. --- IIim.orig 2004-05-09 23:04:19.297215883 -1000 +++ IIim 2004-05-09 23:14:42.989597637 -1000 @@ -16,11 +16,16 @@ test -x $HTT || exit 0 start() { - echo -n $"Starting IIIMF input server: " - daemon --user htt $HTT $OPTIONS 2>&1 </dev/null - echo - RETVAL=$? - [ $RETVAL -eq 0 ] && touch $LOCKER + if [ ! -f $LOCKER ]; then + echo -n $"Starting IIIMF input server: " + daemon --user htt $HTT $OPTIONS 2>&1 </dev/null + echo + RETVAL=$? + [ $RETVAL -eq 0 ] && touch $LOCKER + else + return 0 + fi + return $RETVAL } stop() { @@ -46,7 +51,7 @@ start ;; condrestart) - if [ -f /var/lock/subsys/htt ]; then + if [ -f $LOCKER ]; then stop start fi