I am starting to convert all of our systems to using upstart to manage our various application processes. One thing that I am constantly missing is the ability to send a different signal to the process on stop or restart events.

For instance, we run our web processes with Unicorn. Unicorn has a great signal handling API. When I want to gracefully reload the process I send the master pid a USR2 signal. To shut them down gracefully I send a QUIT command. TERM (upstart's default stop signal) constitutes an immediate shutdown.

Another example is using Resque. To gracefully shut down a worker I send it the QUIT signal. The TERM signal again causes immediate shutdown, whether the worker's child is forked or not.

Does upstart support custom signals? I can't seem to find it anywhere, which worries me that I'm using the "wrong tool for the job".

link|improve this question
feedback

1 Answer

up vote 1 down vote accepted

There are kill signal and kill timeout which would configure relevant signal and timeout values. The "reload" signal is hardcoded to SIGHUP AFAICS.

link|improve this answer
Good to know, not sure why the reload signal is hardcoded but I guess I'll have to live with it for the time being. – localshred Feb 22 at 2:42
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.