Skip to content

Loading…

Crash on file descriptor related error #23

Open
mateodelnorte opened this Issue · 2 comments

2 participants

@mateodelnorte

When fielding requests, bouncy crashes sporadically with the following error:

net.js:722
        self.fd = socket(self.type);
                  ^
Error: EMFILE, Too many open files
    at net.js:722:19
    at Object.lookup (dns.js:153:45)
    at Socket.connect (net.js:716:20)
    at Object.createConnection (net.js:265:5)
    at /Users/matt/Development/vayafeliz.node/node_modules/bouncy/lib/parse_args.js:47:31
    at /Users/matt/Development/vayafeliz.node/node_modules/bouncy/index.js:72:20
    at /Users/matt/Development/vayafeliz.node/proxy.js:27:7
    at IncomingMessage.onHeaders (/Users/matt/Development/vayafeliz.node/node_modules/bouncy/index.js:55:13)
    at IncomingMessage.emit (events.js:64:17)
    at Parser.<anonymous> (/Users/matt/Development/vayafeliz.node/node_modules/bouncy/node_modules/parsley/lib/modes.js:135:21)

This gist contains my bouncy proxy code:

https://gist.github.com/06d3df6d4665f1f13582

@contra

Try setting {headers: {Connection: 'close'}} in opts for bounce

@ghost

Perhaps try increasing maximum number of open file descriptors http://ss64.com/bash/ulimit.html for the processes' user, as a socket is a file descriptor

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.