[rt-users] Help - memory leak problems

douglas.borrie at eject.co.za douglas.borrie at eject.co.za
Fri Oct 17 05:24:57 EDT 2003


This is complete apache config

ServerType standalone
ServerRoot "/usr/local/apache_1.3.28"
PidFile /usr/local/apache_1.3.28/logs/httpd.pid
ScoreBoardFile /usr/local/apache_1.3.28/logs/httpd.scoreboard
Timeout 300
KeepAlive On
MaxKeepAliveRequests 100
KeepAliveTimeout 15
MinSpareServers 5
MaxSpareServers 10
StartServers 5
MaxClients 50
MaxRequestsPerChild 0
Port 80
User nobody
Group nobody
ServerAdmin serveradmin at host.domain.name
ServerName host.domain.name
DocumentRoot "/usr/local/apache_1.3.28/htdocs"

<Directory />
    Options FollowSymLinks
    AllowOverride None
</Directory>

<Directory "/usr/local/apache_1.3.28/htdocs">
    Options Indexes FollowSymLinks MultiViews
    AllowOverride None
    Order allow,deny
    Allow from all
</Directory>

<IfModule mod_userdir.c>
    UserDir public_html
</IfModule>

<IfModule mod_dir.c>
    DirectoryIndex index.html
</IfModule>

AccessFileName .htaccess
<Files ~ "^\.ht">
    Order allow,deny
    Deny from all
    Satisfy All
</Files>

UseCanonicalName On

<IfModule mod_mime.c>
    TypesConfig /usr/local/apache_1.3.28/conf/mime.types
</IfModule>

DefaultType text/plain

<IfModule mod_mime_magic.c>
    MIMEMagicFile /usr/local/apache_1.3.28/conf/magic
</IfModule>

HostnameLookups Off

ErrorLog /usr/local/apache_1.3.28/logs/error_log
LogLevel warn
LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\""
combined
LogFormat "%h %l %u %t \"%r\" %>s %b" common
LogFormat "%{Referer}i -> %U" referer
LogFormat "%{User-agent}i" agent
CustomLog /usr/local/apache_1.3.28/logs/access_log common

ServerSignature Off

<IfModule mod_alias.c>
    Alias /icons/ "/usr/local/apache_1.3.28/icons/"
    <Directory "/usr/local/apache_1.3.28/icons">
        Options Indexes MultiViews
        AllowOverride None
        Order allow,deny
        Allow from all
    </Directory>

    Alias /manual/ "/usr/local/apache_1.3.28/htdocs/manual/"
    <Directory "/usr/local/apache_1.3.28/htdocs/manual">
        Options Indexes FollowSymlinks MultiViews
        AllowOverride None
        Order allow,deny
        Allow from all
    </Directory>

    ScriptAlias /cgi-bin/ "/usr/local/apache_1.3.28/cgi-bin/"
    <Directory "/usr/local/apache_1.3.28/cgi-bin">
        AllowOverride None
        Options None
        Order allow,deny
        Allow from all
    </Directory>
</IfModule>

<IfModule mod_autoindex.c>
    IndexOptions FancyIndexing
    AddIconByEncoding (CMP,/icons/compressed.gif) x-compress x-gzip
    AddIconByType (TXT,/icons/text.gif) text/*
    AddIconByType (IMG,/icons/image2.gif) image/*
    AddIconByType (SND,/icons/sound2.gif) audio/*
    AddIconByType (VID,/icons/movie.gif) video/*

    AddIcon /icons/binary.gif .bin .exe
    AddIcon /icons/binhex.gif .hqx
    AddIcon /icons/tar.gif .tar
    AddIcon /icons/world2.gif .wrl .wrl.gz .vrml .vrm .iv
    AddIcon /icons/compressed.gif .Z .z .tgz .gz .zip
    AddIcon /icons/a.gif .ps .ai .eps
    AddIcon /icons/layout.gif .html .shtml .htm .pdf
    AddIcon /icons/text.gif .txt
    AddIcon /icons/c.gif .c
    AddIcon /icons/p.gif .pl .py
    AddIcon /icons/f.gif .for
    AddIcon /icons/dvi.gif .dvi
    AddIcon /icons/uuencoded.gif .uu
    AddIcon /icons/script.gif .conf .sh .shar .csh .ksh .tcl
    AddIcon /icons/tex.gif .tex
    AddIcon /icons/bomb.gif core

    AddIcon /icons/back.gif ..
    AddIcon /icons/hand.right.gif README
    AddIcon /icons/folder.gif ^^DIRECTORY^^
    AddIcon /icons/blank.gif ^^BLANKICON^^

    DefaultIcon /icons/unknown.gif
    ReadmeName README
    HeaderName HEADER
</IfModule>

<IfModule mod_mime.c>
    AddLanguage da .dk
    AddLanguage nl .nl
    AddLanguage en .en
    AddLanguage et .ee
    AddLanguage fr .fr
    AddLanguage de .de
    AddLanguage el .el
    AddLanguage he .he
    AddCharset ISO-8859-8 .iso8859-8
    AddLanguage it .it
    AddLanguage ja .ja
    AddCharset ISO-2022-JP .jis
    AddLanguage kr .kr
    AddCharset ISO-2022-KR .iso-kr
    AddLanguage nn .nn
    AddLanguage no .no
    AddLanguage pl .po
    AddCharset ISO-8859-2 .iso-pl
    AddLanguage pt .pt
    AddLanguage pt-br .pt-br
    AddLanguage ltz .lu
    AddLanguage ca .ca
    AddLanguage es .es
    AddLanguage sv .sv
    AddLanguage cs .cz .cs
    AddLanguage ru .ru
    AddLanguage zh-TW .zh-tw
    AddCharset Big5         .Big5    .big5
    AddCharset WINDOWS-1251 .cp-1251
    AddCharset CP866        .cp866
    AddCharset ISO-8859-5   .iso-ru
    AddCharset KOI8-R       .koi8-r
    AddCharset UCS-2        .ucs2
    AddCharset UCS-4        .ucs4
    AddCharset UTF-8        .utf8

    <IfModule mod_negotiation.c>
        LanguagePriority en da nl et fr de el it ja kr no pl pt pt-br ru ltz ca
es sv tw
    </IfModule>
    AddType application/x-tar .tgz
    AddEncoding x-compress .Z
    AddEncoding x-gzip .gz .tgz
</IfModule>
<IfModule mod_setenvif.c>
    BrowserMatch "Mozilla/2" nokeepalive
    BrowserMatch "MSIE 4\.0b2;" nokeepalive downgrade-1.0 force-response-1.0
    BrowserMatch "RealPlayer 4\.0" force-response-1.0
    BrowserMatch "Java/1\.0" force-response-1.0
    BrowserMatch "JDK/1\.0" force-response-1.0
</IfModule>

NameVirtualHost *
<VirtualHost host.domain.name>
        ServerName host.domain.name
        DocumentRoot /opt/rt3/share/html
        AddDefaultCharset UTF-8
        PerlRequire /opt/rt3/bin/webmux.pl
        <Location />
                SetHandler perl-script
                PerlHandler RT::Mason
        </Location>
</VirtualHost>

Quoting "Ruslan U. Zakirov" <cubic at acronis.ru>:

> douglas.borrie at eject.co.za wrote:
> Look through all config not only VirtualHost section.
> 
> > This was my previous config
> > 
> > <VirtualHost host.domain.name>
> >         ServerName host.domain.name
> >         DocumentRoot /opt/rt3/share/html
> >         AddDefaultCharset UTF-8
> > 
> >         PerlModule Apache::DBI
> >         PerlRequire /opt/rt3/bin/webmux.pl
> > 
> >         <Location />
> >                 SetHandler perl-script
> >                 PerlHandler RT::Mason
> >         </Location>
> > </VirtualHost>
> > 
> > I changed it to this (is this what you meant by turning off Apache::DBI?)
> > 
> > <VirtualHost host.domain.name>
> >         ServerName host.domain.name
> >         DocumentRoot /opt/rt3/share/html
> >         AddDefaultCharset UTF-8
> > 
> >         PerlRequire /opt/rt3/bin/webmux.pl
> > 
> >         <Location />
> >                 SetHandler perl-script
> >                 PerlHandler RT::Mason
> >         </Location>
> > </VirtualHost>
> > 
> > If that is what you meant, then yes the issue is still there.
> > 
> > 
> > Quoting Jesse Vincent <jesse at bestpractical.com>:
> > 
> > 
> >>Do you still see this issue if you turn off Apache::DBI?
> >>
> >>
> >>On Fri, Oct 17, 2003 at 10:19:28AM +0200, douglas.borrie at eject.co.za
> wrote:
> >>
> >>>Hi all
> >>> 
> >>>I recently installed RT 3.0.4 (and later RT 3.0.6) using apache 1.3.28
> and
> >>>mod_perl 1.29 statically linked.
> >>>I followed all the installation instructions and have installed it on a
> >>
> >>Solaris
> >>
> >>>2.6 as well as a Redhat Linux 9
> >>>box but with the same problem occuring on both.
> >>>The problem appears to be some sort of memory leak where memory is
> >>
> >>allocated but
> >>
> >>>is never released.
> >>>The size of the httpd processes grow after every request.
> >>>The end result is that all RAM is consumed and after a while all swap is
> >>
> >>also
> >>
> >>>exhausted.
> >>> 
> >>>Below are samples taken of the relevant processes (top output - sorted by
> >>
> >>memory
> >>
> >>>usage) while a dummy load is applied.
> >>>The load is generated by multiple web clients with a URL similar to the
> >>>following
> >>>http://host.domain.name/index.html?HomeRefreshInterval=2 (Refresh the
> home
> >>
> >>page
> >>
> >>>every 2 seconds - too speed things up a bit)
> >>> 
> >>>As you'll see the size of the processes grow and eventually all memory is
> >>
> >>used.
> >>
> >>>The only thing that I have found to help is to set MaxRequestsPerChild=1
> >>
> >>in
> >>
> >>>apache config,
> >>>but performance is really bad as after each request is handled that
> apache
> >>
> >>child
> >>
> >>>is killed and another
> >>>is restarted in it's place. I also have to limit MinSpareServers and
> >>>MaxSpareServers to about 4 with
> >>>MaxClients also set to 4.
> >>> 
> >>>I have searched through the mailing list archives but I don't see anybody
> >>
> >>else
> >>
> >>>with
> >>>the same problem (some are similar but I don't seem to find a solution)
> >>> 
> >>>I would really appreciate any help you could give me.
> >>> 
> 
> This email was scanned by ICL's anti-virus solution at
> http://www.eject.co.za
> 
> 


This email was scanned by ICL's anti-virus solution at http://www.eject.co.za



More information about the rt-users mailing list