Since this post has gotten a lot of attention over the years, I\'ve listed the top solutions per platform at the bottom of this post.
Original post
The accepted answer is probably the best production answer, but for a quick hack doing dev work, I found this:
nodejs scriptname.js &
didn't work, because nodejs seemed to gobble up the &, and so the thing didn't let me keep using the terminal without scriptname.js dying.
But I put nodejs scriptname.js
in a .sh file, and
nohup sh startscriptname.sh &
worked.
Definitely not a production thing, but it solves the "I need to keep using my terminal and don't want to start 5 different terminals" problem.