As you can see, as soon as node exits process.stdin goes back to bash rather than being handled by ping. runs in foreground when not detached (this works as documented, I'm using it as an example as ...