On Tue, 20 Mar 2001, Tim Gardner wrote:
> I have been trying to reduce/tune the memory requirements of an
> online game which uses mod_perl (Apache::Registry). I have read the
> suggestions at http://perl.apache.org/tuning/ and am trying to follow
> them. The first suggestion is to preload the modules by including
>
> Perlrequire /var/www/perllib/startup.perl
>
> in httpd.conf and then in startup.perl doing:
>
> #! /usr/local/bin/perl
> use strict;
> use lib "/var/www/perllib";
> use Apache::DBI ();
> use mymodules ();
> 1;
>
> According to the web page:
> >What this does is pull in all of the code used by the programs (but
> >does not import any of the module methods) into the main HTTPD
> >process, which then creates the child processes with the code
> >already in place.
>
> I have been monitoring memory usage with the command:
> ps -ely | grep http
>
> and getting output that looks something like this.
>
> S UID PID PPID C PRI NI RSS SZ WCHAN TTY TIME CMD
> S 1003 318 1 0 40 18 4432 40960 ? ? 4:37 cshttpd
> S 1003 345 318 0 40 18 3320 40920 ? ? 0:02 cshttpd
> S 0 2835 1 0 41 20 8776 10344 ? ? 0:34 httpd
> S 60001 4895 2835 0 41 20 13272 18872 ? ? 0:06 httpd
> S 60001 4894 2835 0 41 20 13280 18872 ? ? 0:07 httpd
>
> I understand that the RSS is the resident size in KB and the SZ
> column is the size of the process, but what should I be seeing in the
> way of reduced memory? The 13MB/18MB is not much different from when
> I don't preload anything. Should I be seeing something else? I
> probably am not understanding what to look for. Any suggestions or
> observations would be appreciated.
You want to read the first sections of:
http://perl.apache.org/guide/performance.html
particularly:
http://perl.apache.org/guide/performance.html#Know_Your_Operating_System
_____________________________________________________________________
Stas Bekman JAm_pH -- Just Another mod_perl Hacker
http://stason.org/ mod_perl Guide http://perl.apache.org/guide
mailto:[EMAIL PROTECTED] http://apachetoday.com http://eXtropia.com/
http://singlesheaven.com http://perl.apache.org http://perlmonth.com/