Cookie - What should I do when the apache ab stress testing tool requires user login to measure?
黄舟
黄舟 2017-05-16 17:04:57
0
1
522

-Explanation of C parameters:

-C cookie-name=value Attach a Cookie: line to the request. Its typical form is a parameter pair of name=value. This parameter can be repeated.

Who can give an example?

黄舟
黄舟

人生最曼妙的风景,竟是内心的淡定与从容!

reply all(1)
phpcn_u1582

First build a "logged in" session and write down the cookie value (Session ID) that identifies this session.
If only one cookie is used:
ab -n 100 -C Key1=Value1
If you need multiple cookies, just set the Header directly:
ab -n 100 -H “Cookie: Key1=Value1; Key2=Value2”

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template