+ Post New Thread
Results 1 to 3 of 3
Virtual Learning Platforms Thread, Moodle server crashing due to apache using too much memory? in Technical; HAs anyone else had this issue? I am running moodle 2.5 on a virtual server with 8Gbytes of memory on ...
  1. #1
    reggiep's Avatar
    Join Date
    Apr 2008
    Location
    In the vast area of space and time
    Posts
    1,548
    Thank Post
    517
    Thanked 56 Times in 50 Posts
    Rep Power
    29

    Moodle server crashing due to apache using too much memory?

    HAs anyone else had this issue?
    I am running moodle 2.5 on a virtual server with 8Gbytes of memory on ubuntu, having moved from running it on an old pc!

    Anyway now when more than about 16 students log in moodle starts to struggle and then gives up, and I get errors "Out of memory: Kill process 5458 (apache2)"
    running top before the crash shows an awful lot of apache processes.

    Is there a way to manage how apache manages its memory usage and amount of processes?

    Thanks

  2. #2


    Join Date
    May 2009
    Posts
    2,938
    Thank Post
    259
    Thanked 773 Times in 588 Posts
    Rep Power
    284
    Generally [*1] you need to look at the parameters associated with the prefork module :

    StartServers, MinSpareServers, MaxSpareServers, ServerLimit, MaxClients, MaxRequestsPerChild.

    I found some good info on optimising Apache for wordpress (this one is particularly relevant), much of that will apply to Moodle. Generally, figure out your overheads (MySQL, the core Apache service and any other memory resident processes), figure out the size of the process Apache uses to service a Moodle connection, then given your RAM, set the parameters such that you don't run out of RAM and start paging.

    [*1] This may not be true if apache2 is configured into worker mode, but that should be unlikely.
    Last edited by pcstru; 27th February 2014 at 09:55 AM.

  3. #3


    Join Date
    Dec 2005
    Location
    In the server room, with the lead pipe.
    Posts
    4,630
    Thank Post
    275
    Thanked 777 Times in 604 Posts
    Rep Power
    223
    Apache (even in as-shipped default config) shouldn't be running out of ram with 16 students and 8GB of RAM.

    show us the output of the "top" command (or better yet, "htop" - you'll need to install it) so we can see what's consuming the RAM.

    ....unless you've got a bizarre apache config.

SHARE:
+ Post New Thread

Similar Threads

  1. Pointing to our Linux Moodle Server
    By papakura in forum Windows
    Replies: 7
    Last Post: 10th July 2012, 09:29 AM
  2. How to increase file upload size on Moodle - Server 2008
    By witch in forum Virtual Learning Platforms
    Replies: 19
    Last Post: 14th September 2010, 01:47 PM
  3. Is Moodle any less likely to be used than any other VLE?
    By witch in forum Virtual Learning Platforms
    Replies: 22
    Last Post: 21st May 2009, 08:10 AM
  4. External Moodle Site LDAP link to school server
    By stephenwelch in forum Virtual Learning Platforms
    Replies: 4
    Last Post: 19th May 2008, 01:37 PM
  5. Getting Moodle to logon using a different https port
    By p.simmons in forum Web Development
    Replies: 9
    Last Post: 8th March 2006, 02:35 PM

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •