title: nodejs Error: write Unknown system errno 5 at errnoException (net.js:642:11) at Object.afterWrite [as oncomplete] (net.js:480:18)
body: <p>I have developed a TCP server application based on nodes, but this app crashes after a while, as soon as someone connects and sends the data on the port, I took a stack trace using <a href="/questions/tagged/winston" class="post-tag" title="show questions tagged 'winston'" rel="tag">winston</a>:</p>
  
  <pre><code>{
      "process": {
          "pid": 28214,
          "uid": 0,
          "gid": 0,
          "cwd": "/home/ec2-user",
          "execPath": "/home/ec2-                user/node/out/Release/node",
          "version": "v0.6.10",
          "argv": [
              "node",
              "/home/ec2-user/Node_TcpServer.js"
          ],
          "memoryUsage": {
              "rss": 12144640,
              "heapTotal": 5274304,
              "heapUsed": 3318328
          }
      },
      "os": {
          "loadavg": [
              0.0029296875,
              0.0146484375,
              0.04541015625
          ],
          "uptime": 779924.506942403
      },
      "trace": [
          {
              "column": 11,
              "file": "net.js",
              "function": "errnoException",
              "line": 642,
              "method": null,
              "native": false
          },
          {
              "column": 18,
              "file": "[as oncomplete] (net.js",
              "function": "Object.afterWrite",
              "line": 480,
              "method": "afterWrite",
              "native": false
          }
      ],
      "stack": [
          "Error: write Unknown system errno 5",
          "    at errnoException (net.js:642:11)",
          "    at Object.afterWrite [as oncomplete] (net.js:480:18)"
      ],
      "level": "error",
      "message": "uncaughtException"
  }
  
  {"process":{"pid":28214,"uid":0,"gid":0,"cwd":"/home/ec2-user","execPath":"/home/ec2-user/node/out/Release/node","version":"v0.6.10","argv":["node","/home/ec2-user/Node_TcpServer.js"],"memoryUsage":{"rss":12230656,"heapTotal":5274304,"heapUsed":3470656}},"os":{"loadavg":[0.0029296875,0.0146484375,0.04541015625],"uptime":779924.509452039},"trace":[{"column":11,"file":"net.js","function":"errnoException","line":642,"method":null,"native":false},{"column":18,"file":"[as oncomplete] (net.js","function":"Object.afterWrite","line":480,"method":"afterWrite","native":false}],"stack":["Error: write Unknown system errno 5","    at errnoException (net.js:642:11)","    at Object.afterWrite [as oncomplete] (net.js:480:18)"],"level":"error","message":"uncaughtException"} "
  </code></pre>