Monday, November 22, 2004

Apache make_sock errors

While trying to resolve a latency issue today, I restarted apache and kept seeing these errors:

[Mon Nov 22 12:12:57 2004] [info] (2)No such file or directory: make_sock: for port 443, setsockopt: (SO_ACCEPTFILTER)
[Mon Nov 22 12:12:57 2004] [info] (2)No such file or directory: make_sock: for port 80, setsockopt: (SO_ACCEPTFILTER)

The port seemed to be bound but wouldn't accept any connections. After running "sockstat" a lot and scratching my head, something occurred to me. I normally have an ipfw throttle pipe running just to prevent an attack or sudden popularity increase in a website or image from sucking up thousands of dollars of bandwidth. I *thought* I had disabled it with "ipfw pipe flush" to troubleshoot the latency problem, but then I remembered that you need to issue two commands to fully clear the ipfw throttling rules:

ipfw pipe flush
ipfw flush

That solved the problem with Apache not accepting socket connections.

(As of this writing, the latency is still there, but I'm growing more and more certain that it's a problem somwhere upstream.)

No comments: