惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

S
Security Affairs
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
CTFtime.org: upcoming CTF events
CTFtime.org: upcoming CTF events
Jina AI
Jina AI
P
Palo Alto Networks Blog
GbyAI
GbyAI
大猫的无限游戏
大猫的无限游戏
A
Arctic Wolf
Hugging Face - Blog
Hugging Face - Blog
小众软件
小众软件
Y
Y Combinator Blog
T
The Blog of Author Tim Ferriss
Blog — PlanetScale
Blog — PlanetScale
S
Schneier on Security
V
Vulnerabilities – Threatpost
C
Cybersecurity and Infrastructure Security Agency CISA
雷峰网
雷峰网
T
Tenable Blog
人人都是产品经理
人人都是产品经理
T
Tor Project blog
C
Cyber Attacks, Cyber Crime and Cyber Security
AWS News Blog
AWS News Blog
Microsoft Security Blog
Microsoft Security Blog
J
Java Code Geeks
Scott Helme
Scott Helme
SecWiki News
SecWiki News
C
CERT Recently Published Vulnerability Notes
Recorded Future
Recorded Future
I
InfoQ
Security Archives - TechRepublic
Security Archives - TechRepublic
Help Net Security
Help Net Security
Cloudbric
Cloudbric
C
Check Point Blog
Engineering at Meta
Engineering at Meta
TaoSecurity Blog
TaoSecurity Blog
B
Blog
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
博客园_首页
N
News and Events Feed by Topic
云风的 BLOG
云风的 BLOG
MyScale Blog
MyScale Blog
腾讯CDC
量子位
Application and Cybersecurity Blog
Application and Cybersecurity Blog
K
Kaspersky official blog
Vercel News
Vercel News
F
Full Disclosure
T
Troy Hunt's Blog
Forbes - Security
Forbes - Security
S
Security @ Cisco Blogs

Rat's Blog - Apache

Apache环境强制http 301跳转https的方法 - Rat's Blog CentOS 6系统Apache环境配置SSL证书教程 - Rat's Blog Linux VPS下Nginx与Apache环境防盗链设置方法 - Rat's Blog apache端口被异常占用导致无法启动的解决方法 - Rat's Blog
Linux VPS使用Webbench/Apache-ab进行网站压力测试 - Rat's Blog
博主: Rat's · 2018-04-28 · via Rat's Blog - Apache

简介

Webbench是一个在linux下使用的非常简单的网站压测工具。它使用fork()模拟多个客户端同时访问我们设定的URL,测试网站在压力下工作的性能,最多可以模拟3万个并发连接去测试网站的负载能力。

Apache abApache Bench性能测试工具,这是apache免费自带的性能测试工具,就在apachebin目录下,它能模拟多个并发请求,也就是说它主要是用来测试你的网站每秒能处理多少请求的。

安装

如果是测试https的话,使用Apache-ab就可以了。

1、安装Webbench

#Debian/Ubuntu系统
apt-get install gcc make ctags -y
#Centos系统
yum install gcc make ctags -y

#安装Webbench
wget https://www.moerats.com/usr/down/webbench-1.5.tar.gz
tar zxvf webbench-1.5.tar.gz && cd webbench-1.5
make && make install

2、安装Apache

#Centos系统
yum install httpd -y
#Debian/Ubuntu系统
apt-get install apache2 -y

使用

1、Webbench

#使用帮助
webbench -h
#测试命令,-c为并发数;-t为测试时长,单位秒;后面为链接
webbench -c 1000 -t 50 http://www.baidu.com

2、Apache

#使用帮助
ab -h
#测试1,-n为发送请求次数;-c并发数;后面为链接
ab -n 500 -c 400 http://www.baidu.com
#测试2,-t为测试时长,单位秒;-c并发数;后面为链接
ab -t 90 -c 50 http://www.baidu.com

总结

WebbenchApache-ab的测试效果都还可以,只是Webbench不支持https网站,AB倒是可以,不过AB的并发数不能过大,好像需要改配置文件,默认最大1024,如果是用来CC攻击或者网站压力测试,建议找下载文件或者动态图片来试,尽量别做坏事。


版权声明:本文为原创文章,版权归 Rat's Blog 所有,转载请注明出处!

本文链接:https://www.moerats.com/archives/606/

如教程需要更新,或者相关链接出现404,可以在文章下面评论留言。