title: Ubuntu upstart won't respawn
body: <p>This is a problem I've experienced on Ubuntu 11.04, with the two upstart scripts I've made, for Node and Nginx. I'll use Node here as the example. I'm using a fairly standard setup as on tutorials like <a href="http://howtonode.org/deploying-node-upstart-monit" rel="nofollow">http://howtonode.org/deploying-node-upstart-monit</a>:</p>
  
  <pre><code>start on started mountall
  stop on shutdown
  
  respawn
  respawn limit 5 60
  
  sudo -u username /usr/local/bin/node /path/to/app.js 2&gt;&amp;1 &gt;&gt; /var/log/node.log
  </code></pre>
  
  <p>Starts fine with "start app". But then I manually killed the node process to force a restart, and unfortunately upstart didn't respawn it. In fact, upstart <strong>won't</strong> respawn it no matter what I do. It shows the following, all the while not starting Node at all:</p>
  
  <pre><code>&gt; sudo start app
  app start/running, process 15211
  &gt; sudo stop app
  stop: Unknown instance: 
  &gt; sudo status app
  app stop/waiting
  </code></pre>