On 10/1/15 7:17 AM, Rostislav Svoboda wrote:
>> Right this is my concern. The behavior is different as the bash
>> scripts don't exit. They wait for the process to end. Maybe it's
>> correct to be different, I don't know.
>
> If you send signal 10 (kill -l 10 returns USR1) AS got restarted thanks
> while loop -
>
https://github.com/wildfly/wildfly-core/blob/master/core-feature-pack/src...
> and it doesn't matter if you execute it normally or with
> LAUNCH_JBOSS_IN_BACKGROUND
>
> don't know what the real use case is to get it restarted
I'm not certain if you were asking ^^^ in general or just in the context
of these init scripts. The answer in general is this is what allows the
This was in general, thanks for explanation.
R.
:shutdown(restart=true) management operation to work; the
restart=true
causes the process to exit with exit code 10. This relies on the launch
script understanding this exit code and starting a new process.
> wildfly-init-redhat.sh and wildfly-init-debian.sh do restart by stop&&start
> restart)
> $0 stop
> $0 start
> EAP 6.4.3 RPM init.d script does stop&&start too
> restart|reload)
> stop
> sleep 3
> start
> RETVAL=$?
> ;;
>
> There is some magic in the .sh scripts with number 128 and it's related
> wait command / bash / signals
>
http://tldp.org/LDP/Bash-Beginners-Guide/html/sect_12_02.html#sect_12_02_02
>
http://veithen.github.io/2014/11/16/sigterm-propagation.html
>
>>
>> Yeah, it looks like that LAUNCH_IN_BACKGROUND behavior is pretty much
>> implemented
>> to satisfy the init.d script we have and is not really useful if you run
>> it
>> directly.
>
> it is used in:
>
https://github.com/wildfly/wildfly-core/blob/master/core-feature-pack/src...
>
https://github.com/wildfly/wildfly-core/blob/master/core-feature-pack/src...
>
> read kpid < $JBOSS_PIDFILE in stop function
>
>> If that is really so, I am not a fan of having that in standalone.sh
>> directly...
>>
>
> domain.sh has the same mechanism LAUNCH_JBOSS_IN_BACKGROUND + JBOSS_PIDFILE
> If it's removed from both files something will have to be added to the
> init/systemd scripts.
>
> Cheers.
> Rostislav
> _______________________________________________
> wildfly-dev mailing list
> wildfly-dev(a)lists.jboss.org
>
https://lists.jboss.org/mailman/listinfo/wildfly-dev
>
--
Brian Stansberry
Senior Principal Software Engineer
JBoss by Red Hat
_______________________________________________
wildfly-dev mailing list
wildfly-dev(a)lists.jboss.org
https://lists.jboss.org/mailman/listinfo/wildfly-dev