[OE-core] [PATCH 1/1] tcf-agent: add -USR2 to stop/kill initscript

Martin Kelly mkelly at xevo.com
Mon May 1 23:15:12 UTC 2017


Looks like this is addressing the same problem as Jan's patch from 
earlier today. I think the differences are:

- kill vs start-stop-daemon

- Jan removed the retry loop while this patch does not

On 05/01/2017 02:59 PM, brian avery wrote:
> The current initscript was lacking a -USR2 signal in the stop section.
> This resulted in /etc/init.d/tcf-agent stop; taking roughly 10 seconds
> then failing to kill the tcf-agent process. This patch brings us in line
> with how upstream stops the agent.
>
> Fixes [YOCTO #10858]
>
> Signed-off-by: brian avery <brian.avery at intel.com>
> ---
>  meta/recipes-devtools/tcf-agent/tcf-agent/tcf-agent.init | 3 +--
>  1 file changed, 1 insertion(+), 2 deletions(-)
>
> diff --git a/meta/recipes-devtools/tcf-agent/tcf-agent/tcf-agent.init b/meta/recipes-devtools/tcf-agent/tcf-agent/tcf-agent.init
> index 6303280..13497cc 100755
> --- a/meta/recipes-devtools/tcf-agent/tcf-agent/tcf-agent.init
> +++ b/meta/recipes-devtools/tcf-agent/tcf-agent/tcf-agent.init
> @@ -35,7 +35,7 @@ case "$1" in
>          echo -n "Stopping $DAEMON_NAME: "
>          count=0
>          while [ -n "`/bin/pidof $DAEMON_PATH`" -a $count -lt 10 ] ; do
> -            killproc $DAEMON_PATH >& /dev/null
> +            kill -USR2 `pidofproc $DAEMON_PATH`  >& /dev/null
>              sleep 1
>              RETVAL=$?
>              if [ $RETVAL != 0 -o -n "`/bin/pidof $DAEMON_PATH`" ] ; then
> @@ -72,4 +72,3 @@ case "$1" in
>  esac
>
>  exit $RETVAL
> -
>



More information about the Openembedded-core mailing list