|
From: Leif M. <lei...@ta...> - 2010-03-12 17:34:44
|
Christian, I admit that I had not seen this standard base in the past. We are about to release 3.4.0, but will look into how closely we can follow these standards in the near future. In the mean time, the status exit code can be changed in the "status()" function of the shell script. All of the error recovery features of the Wrapper are contained within the wrapper process itself so changes to the shell script will not affect how that works. Thank you for pointing this out. Cheers, Leif On Sat, Mar 13, 2010 at 12:47 AM, <chr...@ic...> wrote: > > Hi, > > while connecting the Linux wrapper start scripts to OCF resource agents for > (optional) HA deployment of our application, I noticed that the exit codes > to neither comply with LSB (Linux standard base) nor OCF specs. I'm > referring to JSW 3.3.9. > See > http://refspecs.freestandards.org/LSB_3.1.1/LSB-Core-generic/LSB-Core-generic/iniscrptact.html for > LSB. > > - running the script as another user (in check_user() function) drops the > exit code and always returns 0. > The exit code should be passed back to the caller. > > - status should exit with 3 if process not running (currently 1) > - status should exit with 1 if process seems to be crashed (currently 1) > > In addition to straightforward success, the following situations are also to > be considered successful: > - running start on a service already running > - running stop on a service already stopped or not running > - running restart on a service already stopped or not running > > I wonder how a change of exit codes would affect the monitoring/restarting > capabilities of JSW? > > regards > Christian |