cvs commit: modperl Changes
dougm 01/07/06 13:33:46 Modified:src/modules/perl Apache.xs t/docs startup.pl .Changes Log: add Apache::add_version_component() function Revision ChangesPath 1.125 +7 -0 modperl/src/modules/perl/Apache.xs Index: Apache.xs === RCS file: /home/cvs/modperl/src/modules/perl/Apache.xs,v retrieving revision 1.124 retrieving revision 1.125 diff -u -r1.124 -r1.125 --- Apache.xs 2001/07/06 16:09:53 1.124 +++ Apache.xs 2001/07/06 20:33:35 1.125 @@ -374,6 +374,13 @@ BOOT: items = items; /*avoid warning*/ +void +add_version_component(name) +const char *name + +CODE: +ap_add_version_component(name); + const char * current_callback(r) Apache r 1.42 +4 -1 modperl/t/docs/startup.pl Index: startup.pl === RCS file: /home/cvs/modperl/t/docs/startup.pl,v retrieving revision 1.41 retrieving revision 1.42 diff -u -r1.41 -r1.42 --- startup.pl2001/06/19 05:26:41 1.41 +++ startup.pl2001/07/06 20:33:41 1.42 @@ -34,6 +34,9 @@ die Wrong Apache.pm loaded: $INC{'Apache.pm'}; } +my $version = defined $^V ? sprintf(v%vd, $^V) : $]; +Apache::add_version_component(Perl/$version); + # BSD/OS 3.1 gets confused with some dynamically loaded code inside evals, # so make sure IO::File is loaded here, rather than later within an eval. # this should not harm any other platforms, since IO::File will be used @@ -66,7 +69,7 @@ $Apache::DoInternalRedirect = 1; $Apache::ERRSV_CAN_BE_HTTP = 1; -$Apache::Server::AddPerlVersion = 1; +#$Apache::Server::AddPerlVersion = 1; #warn ServerStarting=$Apache::ServerStarting\n; #warn ServerReStarting=$Apache::ServerReStarting\n; 1.606 +2 -0 modperl/Changes Index: Changes === RCS file: /home/cvs/modperl/Changes,v retrieving revision 1.605 retrieving revision 1.606 diff -u -r1.605 -r1.606 --- Changes 2001/07/06 20:08:29 1.605 +++ Changes 2001/07/06 20:33:44 1.606 @@ -10,6 +10,8 @@ =item 1.25_01-dev +add Apache::add_version_component() function + make sure Apache::ExtUtils can be found when building inside of the apache source tree, thanks to Jonathan Swartz for the spot
cvs commit: modperl/apaci mod_perl.exp
dougm 01/07/06 13:37:04 Modified:.Changes apacimod_perl.exp Log: add symbols to mod_perl.exp for aix/axkit Revision ChangesPath 1.607 +2 -0 modperl/Changes Index: Changes === RCS file: /home/cvs/modperl/Changes,v retrieving revision 1.606 retrieving revision 1.607 diff -u -r1.606 -r1.607 --- Changes 2001/07/06 20:33:44 1.606 +++ Changes 2001/07/06 20:37:00 1.607 @@ -10,6 +10,8 @@ =item 1.25_01-dev +add symbols to mod_perl.exp for aix/axkit + add Apache::add_version_component() function make sure Apache::ExtUtils can be found when building inside of the 1.4 +7 -1 modperl/apaci/mod_perl.exp Index: mod_perl.exp === RCS file: /home/cvs/modperl/apaci/mod_perl.exp,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- mod_perl.exp 2001/04/17 21:48:55 1.3 +++ mod_perl.exp 2001/07/06 20:37:03 1.4 @@ -1,7 +1,13 @@ #! perl_module mod_perl_sent_header -mod_perl_tie_table sv2request_rec perl_request_rec +mod_perl_tie_table +perl_cmd_perl_FLAG +perl_cmd_perl_TAKE2 +perl_cmd_perl_TAKE1 +perl_cmd_perl_TAKE123 +perl_perl_cmd_cleanup hvrv2table +perl_call_handler
cvs commit: modperl/t/net/perl sym.pl
dougm 01/07/06 13:46:20 Modified:t/net/perl sym.pl Log: shutup Test::Harness warning: Test header seen twice! Revision ChangesPath 1.2 +1 -1 modperl/t/net/perl/sym.pl Index: sym.pl === RCS file: /home/cvs/modperl/t/net/perl/sym.pl,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- sym.pl1998/02/10 21:36:24 1.1 +++ sym.pl2001/07/06 20:46:19 1.2 @@ -16,7 +16,7 @@ my $num = $r-args; $r-send_http_header(text/plain); -print 1..2\n; +print 1..2\n if $num == 1; print ok $num\n; delete $Apache::Registry-{+__PACKAGE__};
cvs commit: modperl Changes
dougm 01/07/06 14:20:03 Modified:.Changes Log: rolling 1.25_01 Revision ChangesPath 1.608 +1 -1 modperl/Changes Index: Changes === RCS file: /home/cvs/modperl/Changes,v retrieving revision 1.607 retrieving revision 1.608 diff -u -r1.607 -r1.608 --- Changes 2001/07/06 20:37:00 1.607 +++ Changes 2001/07/06 21:20:00 1.608 @@ -8,7 +8,7 @@ =over 3 -=item 1.25_01-dev +=item 1.25_01 - July 6, 2001 add symbols to mod_perl.exp for aix/axkit
cvs commit: modperl/lib/Apache SizeLimit.pm
dougm 01/07/06 06:44:41 Modified:.Changes lib/Apache SizeLimit.pm Log: Apache::SizeLimit enhancements [Perrin Harkins [EMAIL PROTECTED]]: - Added support for minimum shared memory and maximum unshared memory settings. - Added extra diagnostics to tell how many requests a process served, how long it lived, and how much shared memory it was using when SizeLimit killed it. Revision ChangesPath 1.602 +7 -0 modperl/Changes Index: Changes === RCS file: /home/cvs/modperl/Changes,v retrieving revision 1.601 retrieving revision 1.602 diff -u -r1.601 -r1.602 --- Changes 2001/06/21 16:11:40 1.601 +++ Changes 2001/07/06 13:44:34 1.602 @@ -10,6 +10,13 @@ =item 1.25_01-dev +Apache::SizeLimit enhancements [Perrin Harkins [EMAIL PROTECTED]]: +- Added support for minimum shared memory and maximum unshared memory +settings. +- Added extra diagnostics to tell how many requests a process served, +how long it lived, and how much shared memory it was using when +SizeLimit killed it. + win32 enhancement: APACHE_SRC can be either the build or install tree [Randy Kobes [EMAIL PROTECTED]] 1.8 +81 -24modperl/lib/Apache/SizeLimit.pm Index: SizeLimit.pm === RCS file: /home/cvs/modperl/lib/Apache/SizeLimit.pm,v retrieving revision 1.7 retrieving revision 1.8 diff -u -r1.7 -r1.8 --- SizeLimit.pm 2000/12/20 18:51:56 1.7 +++ SizeLimit.pm 2001/07/06 13:44:39 1.8 @@ -12,7 +12,10 @@ # in your startup.pl: use Apache::SizeLimit; -$Apache::SizeLimit::MAX_PROCESS_SIZE = 1; # in KB, so this is 10MB +# sizes are in KB +$Apache::SizeLimit::MAX_PROCESS_SIZE = 1; # 10MB +$Apache::SizeLimit::MIN_SHARE_SIZE= 1000; # 1MB +$Apache::SizeLimit::MAX_UNSHARED_SIZE = 12000; # 12MB # in your httpd.conf: PerlFixupHandler Apache::SizeLimit @@ -25,7 +28,9 @@ # in your CGI: use Apache::SizeLimit; -Apache::SizeLimit::setmax(1); # Max Process Size in KB +Apache::SizeLimit::setmax(1); # Max size in KB +Apache::SizeLimit::setmin(1000);# Min share in KB +Apache::SizeLimit::setmax_unshared(12000); # Max unshared size in KB Since checking the process size can take a few system calls on some platforms (e.g. linux), you may want to only check the process size every @@ -66,10 +71,29 @@ technique shown in this module and set my MaxRequestsPerChild value to 6000. +=head1 SHARED MEMORY OPTIONS + +In addition to simply checking the total size of a process, this +module can factor in how much of the memory used by the process is +actually being shared by copy-on-write. If you don't understand how +memory is shared in this way, take a look at the mod_perl Guide at +http://perl.apache.org/guide/. + +You can take advantage of the shared memory information by setting a +minimum shared size and/or a maximum unshared size. Experience on one +heavily trafficked mod_perl site showed that setting maximum unshared +size and leaving the others unset is the most effective policy. This +is because it only kills off processes that are truly using too much +physical RAM, allowing most processes to live longer and reducing the +process churn rate. + =head1 CAVEATS This module is platform dependent, since finding the size of a process -is pretty different from OS to OS, and some platforms may not be supported. +is pretty different from OS to OS, and some platforms may not be +supported. In particular, the limits on minimum shared memory and +maximum shared memory are currently only supported on Linux and BSD. +If you can contribute support for another OS, please do. Currently supported OSes: @@ -87,6 +111,7 @@ For solaris we simply retrieve the size of /proc/self/as, which contains the address-space image of the process, and convert to KB. +Shared memory calculations are not supported. NOTE: This is only known to work for solaris 2.6 and above. Evidently the /proc filesystem has changed between 2.5.1 and 2.6. Can anyone @@ -99,7 +124,8 @@ =item AIX? -Uses BSD::Resource::getrusage() to determine process size. +Uses BSD::Resource::getrusage() to determine process size. Not sure if the +shared memory calculations will work or not. AIX users? =back @@ -121,12 +147,17 @@ use Config; use strict; use vars qw($VERSION $HOW_BIG_IS_IT $MAX_PROCESS_SIZE - $REQUEST_COUNT $CHECK_EVERY_N_REQUESTS); + $REQUEST_COUNT $CHECK_EVERY_N_REQUESTS + $MIN_SHARE_SIZE $MAX_UNSHARED_SIZE $START_TIME); $VERSION = '0.03';
cvs commit: modperl-site/netcraft graph.jpg index.html input.data pseudo-graph.jpg
sbekman 01/07/06 07:42:56 Modified:netcraft graph.jpg index.html input.data pseudo-graph.jpg Log: stats for the last two months, going up again! Revision ChangesPath 1.10 +194 -205 modperl-site/netcraft/graph.jpg Binary file 1.38 +7 -0 modperl-site/netcraft/index.html Index: index.html === RCS file: /home/cvs/modperl-site/netcraft/index.html,v retrieving revision 1.37 retrieving revision 1.38 diff -u -r1.37 -r1.38 --- index.html2001/04/18 16:41:43 1.37 +++ index.html2001/07/06 14:42:51 1.38 @@ -40,8 +40,15 @@ mod_perl has passed Netcraft's limit for publication. (Actually, we passed it in September, but Mike gave it to us anyhow). p + +!-- reports can be retrieved from +http://www.netcraft.com/survey/Reports/200106/mod_perl.txt, +adjust the year/month if needed -- + table cellpadding=3 border=1 trtdSurvey/tdtdhostnames/tdtdunique ip addresses/td/tr +trtd June 2001 /tdtd2802093/tdtd273827/td/tr +trtd May 2001 /tdtd2475367/tdtd265466/td/tr trtd April 2001 /tdtd2482288/tdtd256862/td/tr trtd March 2001 /tdtd2298821/tdtd244201/td/tr trtd February 2001 /tdtd2203353/tdtd230502/td/tr 1.23 +2 -0 modperl-site/netcraft/input.data Index: input.data === RCS file: /home/cvs/modperl-site/netcraft/input.data,v retrieving revision 1.22 retrieving revision 1.23 diff -u -r1.22 -r1.23 --- input.data2001/04/18 16:41:44 1.22 +++ input.data2001/07/06 14:42:52 1.23 @@ -1,3 +1,5 @@ +June 20012802093 273827 +May 2001 2475367 265466 April 2001 2482288 256862 March 2001 2298821 244201 February 20012203353 230502 1.10 +63 -53modperl-site/netcraft/pseudo-graph.jpg Binary file