Moodle shared server stress testing

Moodle shared server stress testing

by Ray Le Couteur -
Number of replies: 1

I have posted problems I have had with Totalchoicehosting and problems with server stress (database usage) in the past, but would like to follow this up after a little testing (albeit with Moodle 1.21).

I still have some installations with TCH (although our main school site is at Moodle.com).

I used the 'hidden' database performance tool within moodle (/admin/dbperformance.php) together with a Windows tool called 'Webserver Stress Tool' (the limited trial edition appears to have no time or usage restrictions) on a TCH server.

This allowed me to simulate 10  active users on the site (each with a click every 5 seconds).

When I set dbpersist = false in config.php, there was no observable effect on the number of database connections. With dbpersist = true there seemed to be an exponential increase (I had to switch the test off after 20 seconds).

I finally reduced the number of 'users' to 4 and still the number of database connections rose rapidly.

My conclusion: dbpersist = true (the default in older Moodle versiosns) is why, with a class of 28 TCH complained about excessive database connections. I suspect there would  be no problem with dbpersist = false, unless this caused excessive cpu usage (but my 10 'users' didn't seem to affect the live cpu usage chart at TCH).

I might do further tests with the webstress tool on multiple PC's.

I do not know if this is an issue with the database setup at TCH, but does illustrate a major 'bottleneck' and its cure with some Moodle setups. I don't know if the same would be true with Moodle v1.4

 

Ray

Average of ratings: -
In reply to Ray Le Couteur

Re: Moodle shared server stress testing

by Steven Day -
Ray,

I'd be interested in learning more. Tonight my account was suspended for db abuse, but I haven't received any detailed information from by host (Surpass) as to the extent of the problem. This naturally concerns me since there is some element of contingency involved. At least TCH sounds willing to work with you on this.

Best,

Steven