After looking into aiccu deeper, I see you have a real problem. You keep the first pid you get from the first fork/clone. At least aiccu uses multiple threads on initialization:
lars@artus:~$ sudo strace -o aiccu.log aiccu start lars@artus:~$ grep clone aiccu.log clone(child_stack=0, flags=CLONE_PARENT_SETTID|SIGCHLD, parent_tidptr=0xbfe8ca94) = 2992 clone(child_stack=0, flags=CLONE_PARENT_SETTID|SIGCHLD, parent_tidptr=0xbfe8ca94) = 2994 clone(child_stack=0, flags=CLONE_CHILD_CLEARTID|CLONE_CHILD_SETTID|SIGCHLD, child_tidptr=0xb773e938) = 2996 lars@artus:~$ ps aux|grep aiccu root 2996 0.0 0.0 19732 832 ? Ssl 10:39 0:00 aiccu start lars@artus:~$ service aiccu status aiccu start/running, process 2992 lars@artus:~$ ps aux|grep 2992 lars 3049 0.0 0.0 3040 792 pts/0 R+ 10:41 0:00 grep 2992
That means: you track pid 2992, which is only used during initialization. Real pid is 2996.
On "service aiccu stop" you try to kill pid 2992 - which is not there, and you keep stuck in a inifinite loop.
After looking into aiccu deeper, I see you have a real problem. You keep the first pid you get from the first fork/clone. At least aiccu uses multiple threads on initialization:
lars@artus:~$ sudo strace -o aiccu.log aiccu startstack=0, flags=CLONE_PARENT_SETTID|SIGCHLD, parent_tidptr=0xbfe8ca94) = 2992stack=0, flags=CLONE_PARENT_SETTID|SIGCHLD, parent_tidptr=0xbfe8ca94) = 2994stack=0, flags=CLONE_CHILD_CLEARTID|CLONE_CHILD_SETTID|SIGCHLD, child_tidptr=0xb773e938) = 2996
lars@artus:~$ grep clone aiccu.log
clone(child_
clone(child_
clone(child_
lars@artus:~$ ps aux|grep aiccu
root 2996 0.0 0.0 19732 832 ? Ssl 10:39 0:00 aiccu start
lars@artus:~$ service aiccu status
aiccu start/running, process 2992
lars@artus:~$ ps aux|grep 2992
lars 3049 0.0 0.0 3040 792 pts/0 R+ 10:41 0:00 grep 2992
That means: you track pid 2992, which is only used during initialization. Real pid is 2996.
On "service aiccu stop" you try to kill pid 2992 - which is not there, and you keep stuck in a inifinite loop.