[Twisted-Python] epoll reactor problems

Thomas Hervé therve at free.fr
Wed Apr 11 05:42:59 EDT 2007

Quoting Alec Matusis <matusis at matusis.com>:

>> We would probably need more information. What's your version of python?
> We are using Python 2.4.1

That's old (debian stable ? :)). I don't say that'll solve your 
problem, but you
could try with 2.4.4 (warning, not 2.4.3).

>> Can you
>> provide a reproductible example?
> It's hard to provide a reproducible example: we observe this problem only on
> the live servers. So I do not know how to simplify the code (it has 40000+
> lines) such that the problem still remains, since we would have to try it on
> real users...


> Did you try to do a strace on your
>> running
>> server to see what's going on?
> I did run strace- it made the server unresponsive, so it had to be
> restarted. Here is the output from the problematic server at 99% CPU:

> epoll_wait(4, {{EPOLLERR|EPOLLHUP, {u32=1023, u64=12304606485815493631}},
> POLLMSG|EPOLLERR|EPOLLHUP|0x7820, {u32=5529648, u64=5529648}},
> u64=22827751178240}}, {0, {u32=0, u64=0}},
> u64=18097643565645823}}}, 1434, 30) = 5

This part is highly suspect. The flags on the fd should not reach these 

What's the global state of the process? Memory, number of opened fd ?


More information about the Twisted-Python mailing list