Created
March 25, 2010 09:38
-
-
Save hiratara/343369 to your computer and use it in GitHub Desktop.
My bad configuration of mod_proxy and Starman
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
% starman --listen :21081 www/index.psgi | |
でStarmanを起動しておくと、 | |
% ab -c 5 -n 500 http://127.0.0.1:21082/ | |
を10回くらいやると、ひっかかるリクエストが出てレスポンスが極端に悪くなる。 | |
Percentage of the requests served within a certain time (ms) | |
50% 1 | |
66% 1 | |
75% 1 | |
80% 1 | |
90% 4 | |
95% 1008 | |
98% 1994 | |
99% 2003 | |
100% 2020 (longest request) | |
% starman --workers 10 --listen :21081 www/index.psgi | |
とすると、問題なし。 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
LoadModule proxy_module /usr/libexec/apache2/mod_proxy.so | |
LoadModule proxy_http_module libexec/apache2/mod_proxy_http.so | |
ServerRoot /tmp/test_proxy | |
PidFile logs/httpd.pid | |
LockFile logs/accept.lock | |
Listen 21082 | |
DocumentRoot /tmp/test_proxy/www | |
ProxyPass / http://127.0.0.1:21081/ | |
# % httpd -l | |
# Compiled in modules: | |
# core.c | |
# prefork.c | |
# http_core.c | |
# mod_so.c |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sub { [200, [ | |
'Content-Type' => 'text/plain', | |
'Content-Length' => '6', | |
], ["HELLO\n"] ] }; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment