WeBWorK Main Forum

WebWork server constantly using lots of memory

WebWork server constantly using lots of memory

by Subasa Nguyen -
Number of replies: 3
Hello everyone,

I'm having issues with my WebWork installation.
Please take a look at the screenshot.

Memory the majority of time shows it's very close to running out ( ~80% )

We have about 3000 students taking courses that are hosted on this WebWork server.

Right now when I do a

# netstat -plan|grep :80|awk {'print $5'}|cut -d: -f 1|sort|uniq -c|sort -nk 1

i'm only seeing a few IPs, and yet memory is at 12GB....

Please advise, thank you....


Sava
Attachment CaptureWW.PNG
In reply to Subasa Nguyen

Re: WebWork server constantly using lots of memory

by Subasa Nguyen -
Last week, due to numerous reports from students that they couldn't access the WebWork site, I had to make some changes.

apache2.conf

<IfModule mpm_prefork_module>
    StartServers          8
    MinSpareServers       5
    MaxSpareServers      20
    MaxClients           256
    MaxRequestsPerChild 4000
</IfModule>

# worker MPM
# StartServers: initial number of server processes to start
# MinSpareThreads: minimum number of worker threads which are kept spare
# MaxSpareThreads: maximum number of worker threads which are kept spare
# ThreadLimit: ThreadsPerChild can be changed to this maximum value during a
#              graceful restart. ThreadLimit can only be changed by stopping
#              and starting Apache.
# ThreadsPerChild: constant number of worker threads in each server process
# MaxClients: maximum number of simultaneous client connections
# MaxRequestsPerChild: maximum number of requests a server process serves
<IfModule mpm_worker_module>
    StartServers          4
    MinSpareThreads      25
    MaxSpareThreads      75
    ThreadLimit          64
    ThreadsPerChild      25
    MaxClients          256
    MaxRequestsPerChild   0
</IfModule>

# event MPM
# StartServers: initial number of server processes to start
# MinSpareThreads: minimum number of worker threads which are kept spare
# MaxSpareThreads: maximum number of worker threads which are kept spare
# ThreadsPerChild: constant number of worker threads in each server process
# MaxClients: maximum number of simultaneous client connections
# MaxRequestsPerChild: maximum number of requests a server process serves
<IfModule mpm_event_module>
    StartServers          2
    MinSpareThreads      25
    MaxSpareThreads      75
    ThreadLimit          64
    ThreadsPerChild      25
    MaxClients          150
    MaxRequestsPerChild   0
</IfModule>


and increased memory from 8GB to 16, also vCPU from 2 to 4
In reply to Subasa Nguyen

Re: WebWork server constantly using lots of memory

by Subasa Nguyen -
In reply to Subasa Nguyen

Re: WebWork server constantly using lots of memory

by Danny Glin -