Ensure Django Debug is off.

Don't use mod_python unless you know how to tune Apache MPM settings
properly for a fat persistent Python web application.

Default Apache MPM settings are for static file serving and PHP and
aren't necessarly appropriate for long live web applications.

Consider using mod_wsgi daemon mode or fastcgi/scgi/ajp solutions,
which separate out Python web application out into separate fixed
number of persistent processes.

These latter options will generally work better without you needing to
fiddle with Apache settings.

Graham

On Feb 11, 11:10 pm, Tobias Nyström <i...@avalanchestudios.se> wrote:
> Hi,
>
> First of all, thank you for a great product!
>
> Using alpha2, we have a problem with the server running out of memory.
> Have a setup with apache2 and mod_python and memcached on debian etch,
> and if I restart apache, the problem "goes away" temporarly. Any
> thoughts?
>
> reviewboard:~# free
>              total       used       free     shared    buffers
> cached
> Mem:       1228912    1195532      33380          0         80
> 2304
> -/+ buffers/cache:    1193148      35764
> Swap:       522072     522056         16
>
> reviewboard:~# ps aux
> USER       PID %CPU %MEM    VSZ   RSS TTY      STAT START   TIME
> COMMAND
> root         1  0.0  0.0   1952    92 ?        Ss   Feb04   0:00 init
> [2]
> root         2  0.0  0.0      0     0 ?        S    Feb04   0:00
> [migration/0]
> root         3  0.0  0.0      0     0 ?        SN   Feb04   0:00
> [ksoftirqd/0]
> root         4  0.0  0.0      0     0 ?        S    Feb04   0:00
> [watchdog/0]
> root         5  0.0  0.0      0     0 ?        S<   Feb04   0:00
> [events/0]
> root         6  0.0  0.0      0     0 ?        S<   Feb04   0:00
> [khelper]
> root         7  0.0  0.0      0     0 ?        S<   Feb04   0:00
> [kthread]
> root         9  0.0  0.0      0     0 ?        S<   Feb04   0:00
> [xenwatch]
> root        10  0.0  0.0      0     0 ?        S<   Feb04   0:00
> [xenbus]
> root        16  0.0  0.0      0     0 ?        S<   Feb04   0:00
> [kblockd/0]
> root        18  0.0  0.0      0     0 ?        S<   Feb04   0:00
> [kseriod]
> root        49  0.0  0.0      0     0 ?        S    Feb04   0:00
> [pdflush]
> root        50  0.0  0.0      0     0 ?        D    Feb04   0:00
> [pdflush]
> root        51  0.0  0.0      0     0 ?        D<   Feb04   4:03
> [kswapd0]
> root        52  0.0  0.0      0     0 ?        S<   Feb04   0:00 [aio/
> 0]
> root       659  0.0  0.0      0     0 ?        S<   Feb04   0:00
> [kjournald]
> root       740  0.0  0.0   2184    28 ?        S<s  Feb04   0:00 udevd
> --daemon
> root      1506  0.0  0.0      0     0 ?        S<   Feb04   0:00
> [kmirrord]
> root      1578  0.0  0.0   2660   188 ?        S    Feb04   0:03 /bin/
> bash /usr/sbin/xe-daemon
> root      1764  0.0  0.0   1732   280 ?        Ss   Feb04   0:00 /sbin/
> syslogd
> root      1770  0.0  0.0   1580    24 ?        Ss   Feb04   0:00 /sbin/
> klogd -x
> root      1803  0.0  0.0   4932   164 ?        Ss   Feb04   0:00 /usr/
> sbin/sshd
> root      1818  0.0  0.0   2200   156 ?        Ss   Feb04   0:00 /usr/
> sbin/cron
> root      1854  0.0  0.0   1576    28 tty1     Ss+  Feb04   0:00 /sbin/
> getty 38400 tty1
> root      4382  0.0  0.0      0     0 ?        S<   Feb04   0:00
> [rpciod/0]
> daemon    4478  0.0  0.0   1688    20 ?        Ss   Feb04   0:00 /sbin/
> portmap
> root      4484  0.0  0.0      0     0 ?        S    Feb04   0:00
> [lockd]
> root      3763  0.0  0.0  34072   272 ?        S    Feb09   0:00 /usr/
> bin/memcached -m 64 -p 11211 -u root
> nagios   30952  0.0  0.0   1792    80 ?        Ss   Feb10   0:00 /usr/
> local/nagios/bin/nrpe -c /usr/local/nagios/etc/nrpe-avalanche.cfg -d
> root     14323  0.0  0.0  11824  1120 ?        Ss   00:00   0:00 /usr/
> sbin/apache2 -k start
> www-data 14324  0.0  0.0  10676   328 ?        S    00:00   0:00 /usr/
> sbin/apache2 -k start
> www-data 14325  0.3 59.2 1104644 728444 ?      Sl   00:00   2:55 /usr/
> sbin/apache2 -k start
> www-data 14326  0.3 35.0 1026772 431176 ?      Sl   00:00   2:39 /usr/
> sbin/apache2 -k start
> root      4417  0.1  0.0   7708   860 ?        Ss   12:52   0:00 sshd:
> r...@pts/0
> root      4419  0.2  0.0   2800  1084 pts/0    Ss   12:52   0:00 -bash
> root      4460  0.0  0.0   1568   156 ?        S    12:52   0:00 sleep
> 60
> root      4462  0.0  0.0   2228   908 pts/0    R+   12:53   0:00 ps
> aux
>
> reviewboard:~# /etc/init.d/apache2 restart
> Forcing reload of web server (apache2)... waiting ......
> reviewboard:~# free
>              total       used       free     shared    buffers
> cached
> Mem:       1228912      40560    1188352          0        708
> 8912
> -/+ buffers/cache:      30940    1197972
> Swap:       522072      33640     488432
>
> (ps. I work at the same place as Srekel)
>
> Regrads
> Tobias Nyström
> System Administrator
> Avalanche Studios
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"reviewboard" group.
To post to this group, send email to reviewboard@googlegroups.com
To unsubscribe from this group, send email to 
reviewboard+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/reviewboard?hl=en
-~----------~----~----~----~------~----~------~--~---

  • Memory leak Tobias Nyström
    • Re: Memory leak Graham Dumpleton

Reply via email to