Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I want to reliably restart my app and web server processes on crash.

If I understand correctly, runit starts every service as a child process. If the child process crashes this sends a signal to the parent process which in turn respawns the service as a child.

How does this work in the case of upstart. Does it also spawn a child process like runit?

I am considering using runit for this. Is that needed, or is upstart good enough for this ?

I am using nginx for my web server and gunicorn (python) for my app server.

share|improve this question
add comment

1 Answer

up vote 1 down vote accepted

Upstart is perfect for it, see respawn stanza: http://upstart.ubuntu.com/cookbook/#respawn. Upstart is an init process, pid 1, parent of all other processes.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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