Chigirin / slowhttptest

Automatically exported from code.google.com/p/slowhttptest
Apache License 2.0
0 stars 0 forks source link

99% CPU usage #12

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
- What steps will reproduce the problem?

running a test like 
slowhttptest -c 2000 -X -r 200 -w 512 -y 1024 -n 5 -z 32 -k 8 -u http://testurl 
-p 10 -l 350 

Then monitoring sowhttptest CPU usage with top shows that usage start around 
30% during the connections ramping up phase but when reaching the DDOs state 
then i see a 99% CPU use and my laptop runs hot.

If i use a tool like cpulimit to artificially limit the CPU use of slowhttptest 
to something like 20% it results in a same level of efficiency aka my test url 
is still DOSed, indicating that slowhttptest may not really need to use all 
this power.

- What version of the product are you using? On what operating system?

tested with last release and last trunk on fedora 16 64bit. My laptop is quite 
powerful, it's a core i7 sandybrige. When runnin slowhttptest the CPU 
overclocks itself to 3.4Ghz in order to accomodate the 99% usage. If limited to 
20% my CPU is able to stay cool and limits its clock to a more usual clock 
speed.

Original issue reported on code.google.com by sheepdes...@gmail.com on 10 Apr 2012 at 1:40

GoogleCodeExporter commented 9 years ago
in fact that the testurl is effectively DOSed or not does not seem to matter, 
the CPU usage reach 99% anyway after a while and then stay there. For example i 
have 0 connection pendind, say 1500 connected and the site still up, and the 
500 connexion closed and counting. All the time the slowhttptest will stay 
runing from there it's CPU usage stays at 99%.

Original comment by sheepdes...@gmail.com on 10 Apr 2012 at 1:49

GoogleCodeExporter commented 9 years ago
OMG, I am sorry, seems like google code doesn't notify me of new issues 
reported.
Indeed, with 2K connections CPU usage goes up to 99%. Looks like something is 
wrong in the logic once server starts closing the connections.
Thanks a lot for noticing, will fix this in upcoming release.  

Original comment by shek...@gmail.com on 16 Jul 2012 at 5:39

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
Great :)

Original comment by sheepdes...@gmail.com on 17 Jul 2012 at 8:18

GoogleCodeExporter commented 9 years ago
Fixed in 1.5 version

Original comment by shek...@gmail.com on 7 Sep 2012 at 7:53

GoogleCodeExporter commented 9 years ago
Hi

tested today the last revision but it seems the problem is not solved :

- during initialization phase the cpu stays at around 35% and pending 
connections ramp up :

Fri Sep 21 13:26:37 2012:slow HTTP test status on 30th second:
initializing:        0
pending:             3527
connected:           28
error:               0
closed:              0
service available:   NO
Fri Sep 21 13:26:42 2012:slow HTTP test status on 35th second:
initializing:        0
pending:             4133
connected:           28
error:               0
closed:              0
service available:   NO
Fri Sep 21 13:26:47 2012:slow HTTP test status on 40th second:
initializing:        0
pending:             4781
connected:           28
error:               0
closed:              0
service available:   NO
Fri Sep 21 13:26:52 2012:slow HTTP test status on 45th second:
initializing:        0
pending:             5412
connected:           28
error:               0
closed:              0
service available:   NO
Fri Sep 21 13:26:57 2012:slow HTTP test status on 50th second:
initializing:        0
pending:             5972
connected:           28
error:               0
closed:              0
service available:   NO

- but after all 6000 connections are in pending mode, the cpu usage is now 99% 
and closed connections start increasing:

Fri Sep 21 13:27:12 2012:slow HTTP test status on 65th second:
initializing:        0
pending:             5924
connected:           28
error:               0
closed:              48
service available:   NO
Fri Sep 21 13:27:17 2012:slow HTTP test status on 70th second:
initializing:        0
pending:             5364
connected:           28
error:               0
closed:              608
service available:   NO
Fri Sep 21 13:27:22 2012:slow HTTP test status on 75th second:
initializing:        0
pending:             4769
connected:           28
error:               0
closed:              1203
service available:   NO
Fri Sep 21 13:27:27 2012:slow HTTP test status on 80th second:
initializing:        0
pending:             4193
connected:           28
error:               0
closed:              1779
service available:   NO
Fri Sep 21 13:27:32 2012:slow HTTP test status on 85th second:
initializing:        0
pending:             3606
connected:           28
error:               0
closed:              2366
service available:   NO
Fri Sep 21 13:27:37 2012:slow HTTP test status on 90th second:
initializing:        0
pending:             2997
connected:           28
error:               0
closed:              2975
service available:   NO

- finally i reach a state where almost all connection whent from pending to 
closed, it stays that way for a long time with cpu at 99% and target DoSed:

Fri Sep 21 13:33:17 2012:slow HTTP test status on 430th second:
initializing:        0
pending:             129
connected:           28
error:               0
closed:              5843
service available:   NO
Fri Sep 21 13:33:22 2012:slow HTTP test status on 435th second:
initializing:        0
pending:             129
connected:           28
error:               0
closed:              5843
service available:   NO
Fri Sep 21 13:33:27 2012:slow HTTP test status on 440th second:
initializing:        0
pending:             129
connected:           28
error:               0
closed:              5843
service available:   NO
Fri Sep 21 13:33:32 2012:slow HTTP test status on 445th second:
initializing:        0
pending:             129
connected:           28
error:               0
closed:              5843
service available:   NO
Fri Sep 21 13:33:37 2012:slow HTTP test status on 450th second:
initializing:        0
pending:             129
connected:           28
error:               0
closed:              5843
service available:   NO
Fri Sep 21 13:33:42 2012:slow HTTP test status on 455th second:
initializing:        0
pending:             129
connected:           28
error:               0
closed:              5843
service available:   NO
Fri Sep 21 13:33:47 2012:slow HTTP test status on 460th second:
initializing:        0
pending:             129
connected:           28
error:               0
closed:              5843
service available:   NO
Fri Sep 21 13:33:52 2012:slow HTTP test status on 465th second:
initializing:        0
pending:             129
connected:           28
error:               0
closed:              5843
service available:   NO
Fri Sep 21 13:33:57 2012:slow HTTP test status on 470th second:
initializing:        0
pending:             129
connected:           28
error:               0
closed:              5843
service available:   NO
Fri Sep 21 13:34:02 2012:slow HTTP test status on 475th second:
initializing:        0
pending:             129
connected:           28
error:               0
closed:              5843
service available:   NO
Fri Sep 21 13:34:07 2012:slow HTTP test status on 480th second:
initializing:        0
pending:             129
connected:           28
error:               0
closed:              5843
service available:   NO
Fri Sep 21 13:34:12 2012:slow HTTP test status on 485th second:
initializing:        0
pending:             129
connected:           28
error:               0
closed:              5843
service available:   NO
Fri Sep 21 13:34:17 2012:slow HTTP test status on 490th second:
initializing:        0
pending:             129
connected:           28
error:               0
closed:              5843
service available:   NO

Original comment by sheepdes...@gmail.com on 21 Sep 2012 at 11:35