tornado - 在实践中 C10k 怎么样?

标签 tornado c10k

我刚刚测试了一个使用 Tornado 制作的小应用程序,我离 10k 同时连接还很远!
为了进行测试,我使用了 Siege , 下 OpenSuse 12.2 64 位 ,机器是 i7 8GB
结果如下:

siege -c 4000 localhost:8000

我收到此错误:
Transactions:                   2164 hits
Availability:                  39.90 %
Elapsed time:                   6.85 secs
Data transferred:               2.52 MB
Response time:                  1.04 secs
Transaction rate:             315.91 trans/sec
Throughput:                     0.37 MB/sec
Concurrency:                  329.74
Successful transactions:        2164
Failed transactions:            3260
Longest transaction:            5.94
Shortest transaction:           0.00

如果我使用 10k 连接:
siege -c 10000 localhost:8000

我收到一个错误:
[error] descriptor table full sock.c:109: Too many open files

最佳答案

检查 ulimit 的输出命令。您需要增加 siege 和 tornado 网络服务器上的文件描述符限制才能完成基准测试。

关于tornado - 在实践中 C10k 怎么样?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/15034018/

相关文章:

python - 如何为 python tornado 应用程序编写单元测试?

python - 有没有办法更改 python Tornado Web 框架中的根 URL?

java - 创建数千个 Netty 客户端,而无需创建数千个线程

django - GEvent/GUnicorn 和 C10k 问题

python-2.7 - python 2.7 的 Tornado 需要 asyncio,它只是 python 3+

django - 聊天应用程序 : Using Django with sockjs-tornado and redis

multithreading - Boost:多线程性能,线程/套接字的重用

node.js - 慢速磁盘 I/O 是否会降低 Node.js 应用程序其余部分的性能?

python - 如何在 Tornado 中获取 http referrer?

performance - Web 服务器的理论性能限制是多少?