大网数据广告活动
服务器运维问答

How many requests can a router handle?

· 52CE 我爱测

I made a script to scan a file which contains a portion of ipv4 addresses (about 50 million), it attempts to connect to the website using OpenSSL and extract a small piece of it and writes it into a file. To save some of the deta…

问题原文

原帖链接 · user153882 · CC BY-SA 3.0

I made a script to scan a file which contains a portion of ipv4 addresses (about 50 million), it attempts to connect to the website using OpenSSL and extract a small piece of it and writes it into a file. To save some of the details, it uses multiprocessing to run about 150 workers to connect to different sites at the same time, and each connection takes under a second.

My CPU can handle much more workers, so the script is not CPU bounded by any means. The script caps at the 1/5 of my maximum bandwidth at home and not even a 1/30 of the maximum speed at the university labs (I have special permission to run this), even if I bump up the workers to about 300, 400, 500, etc. It is also definitely not I/O bounded, because it keeps it in a list in memory and writes it out at the end. I believe it is due to the router not being handle so many requests at the same time

  1. Can the router be overloaded with request, even if bandwidth is not an issue. I'm more surprised that the university network cannot handle these requests.

  2. What can I do to solve it? Or any other insights?

已采纳解答

原帖链接 · Cory Knutson · CC BY-SA 3.0

The answer to your question is that it depends heavily on the router. Business class routers are typically rated not only by bandwidth, but but PPS (Packets per second) this is usually in the seven digit range.

As an example, a Ubiquiti Security Gateway Pro 4 is rated at 2.4 million pps.

https://dl.ubnt.com/datasheets/unifi/UniFi_Security_Gateway_DS.pdf on page 4

摘自公开归档,保留原文语言,版式经整理,外部媒体与邮箱地址已移除。

资料来源与适用范围

资料来源
Server Fault
适用范围
以原帖系统、软件版本与发布日期为准(2017-04-04)
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY-SA 3.0

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。