Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a node server (0.6.6) running an Express application, along with Mongoose and s3, on an Ubuntu 11.04 machine.

Several times per hour, the server is hanging. That means that the application is working fine, I see the express loggings, and then all of a sudden the server stops responding. No errors, no traces, no loggings, and strangely enough the browser won't show the request even in the network debugging window. From any machine in the local network it's the same behaviour. I restart the server and it's okay again for several minutes, then again starts to hang, everytime while doing something different.

The same application on Amazon on the same Ubuntu version works fine and never hangs.

I know all this is kind of vague, but I don't know where to start. Has any of you seen something like this before? Any idea?

share|improve this question
Not much help but yes, I've seen the same problem when running node on my mac. – James Butler Mar 3 '12 at 11:25
up vote 3 down vote accepted

So, there's two causes that I've found out could both even for themselves cause the described behaviour.

  1. Piping to a log process. In my upstart script I've had a line saying something like exec su nodejs node /home/nodejs/server.js | /home/nodejs/logger.js this would make the upstart daemon supervise the logging process instead of the server. Thus, a crashing server would go unnoticed and appear to be stalled. (instead, one could use <<< to pipe from right to left)

  2. process.on('uncaughtException', ...) can make the a node app hang. I think one of the modules I've been using had a debug mode that enabled that event.

share|improve this answer

Your Answer


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.