... forgot to say that I have updated the Cookbook on this topic: - http://upstart.ubuntu.com/cookbook/#respawn - http://upstart.ubuntu.com/cookbook/#respawn-limit
2014-03-05 14:51 GMT+00:00 James Hunt <[email protected]>: > Hi Michael, > > 2014-03-04 19:26 GMT+00:00 Michael Barrett <[email protected]>: > > Is there anyway to tell the difference between these different 'stopped' >> situations: >> - The daemon was stopped by a user command (service <daemon> stop) >> > $UPSTART_EVENTS will not be set in this scenario (since no event caused > the job to stop - an admin intervened). > > - The daemon died, but is has not reached the respawn limit and is >> restarting. >> > In this scenario, $PROCESS will be set to the name of the job process > that failed (for example 'pre-start', 'main'). > > - The daemon died and is not going to attempt to respawn due to whatever >> reason (no respawn, or reaching the respawn limit) >> > In this scenario, if the respawn stanzas was specified, $PROCESS will be > set to 'respawn' to denote that the respawn limit was reached. > > If the respawn stanza was not specified, $PROCESS will not be set. > However, in both scenarios upstart will set $EXIT_STATUS or $EXIT_SIGNAL > (whichever is appropriate). > > See stopped(7) and init(5) for further details. > > >> Thanks! >> >> -- >> Michael Barrett >> >> -- >> upstart-devel mailing list >> [email protected] >> Modify settings or unsubscribe at: >> https://lists.ubuntu.com/mailman/listinfo/upstart-devel >> >> > > > -- > Kind regards, > > James. > -- > James Hunt > ____________________________________ > #upstart on freenode > http://upstart.ubuntu.com/cookbook > https://lists.ubuntu.com/mailman/listinfo/upstart-devel > -- Kind regards, James. -- James Hunt ____________________________________ #upstart on freenode http://upstart.ubuntu.com/cookbook https://lists.ubuntu.com/mailman/listinfo/upstart-devel
-- upstart-devel mailing list [email protected] Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/upstart-devel
