Moodle is not really slow, is it?

Moodle is not really slow, is it?

by Art Lader -
Number of replies: 11

A friend mentioned to me yesterday that his Moodle installation served pages very slowly in his current shared-hosting environment. He is reluctant to change hosts, though, because it is his impression that "Moodle is just slow," so moving to another host would not change much.

I am completely out of my depth here. It is not really true that Moodle runs slowly in most hosting environments, is it? (We are hosted at Moodle.com, so we certainly do not have this problem.)

Thanks,
Art

Average of ratings: -
In reply to Art Lader

Re: Moodle is not really slow, is it?

by Michael Penney -
Hi Art, short answer is relativitysmile.

Is Moodle slow compared to other course management systems? IME, the answer is a resounding NO.

Would you even think of running webct in a shared hosting evironment? IIRC, their license forbids you to run any other web apps on the same server. I know Blackboard's license forbids this.

Many lost cost shared hosting cos. are not going to be configured to run numerous installations of complex php (or perl, or java, etc.) apps. because most folks just want a place to put a few web pages for their $5/month. If you are running any sort of database drive site (postnuke, mambo, plone, etc.) where you are expecting to have more than a few people logged in at the same time,  you are going to need alot more horsepower to run it smoothly than someone who is selling server space on a bargin basement rack is going to be able to make any money giving you.

So moodle is certainly 'slow' compared to a simple web form or other minor php app., but it is certainly not slower than other comparable course management systems.

IMO, that your friend can even think of running a production course on a shared environment where webct, blackboard, etc. wouldn't even fire up attests to the fact that Moodle is a pretty efficient course managment system.

My advice would be that he/she should find a host that offers php/mysql support as a core part of the their business (as opposed to folks running php cgi so they can say they support php) and expect to pay a reasonble amount (at least a few $ per student per month) to make sure the system has enough resources to run the CMS at a reasonable speed.

In reply to Michael Penney

Re: Moodle is not really slow, is it?

by Bob Boufford -

Michael,

Just a point of clarification in that the WebCT CE license does not forbid one to run WebCT CE in a shared environment. It's just a best practice that's highly encouraged, to run WebCT CE on it's own server without any other services.  Of course, if one has the horsepower like a Sun Fire E25K, then the issue is moot.

But I do agree completely with you and others that Moodle like the other CMSs, should be the only service running on a server. There are management issues that make it more favorable to have one's own Moodle server instead of sharing a single server.

Also, the perception of "slow" may often be the fault of something outside the server. We are constantly fighting a "CMS is slow" issue even though it's running in a highly tuned 12 node clustered Sun environment. It's often due to network, ISP and local system issues that are out of our control. So in Art's issue, the problem may not just be the hosting service's resources but also the network connnection to the hosting service.

Cheers,

Bob

In reply to Art Lader

Re: Moodle is not really slow, is it?

by Martín Langhoff -
Definitely not slow smile

A few factors make things tricky for Moodle hosting, though.

Web apps, as they get sophisticated, need a good hand to "tune" them. The standard configs of Apache/MySQL/PHP don't work for _any_ web application under heavy usage.

If you have a blog, or a forum, interest grows or wanes in a very granular fashion -- one user at a time. With Moodle, the granularity is very coarse. You add courses, which are large-ish groups of people. Even more seriously, sometimes these groups of people access the app at the exact same time.

This coarse-grained pattern of traffic means that performance problems don't insinuate themselves, they just happen. You are either prepared or you are not.

"And now, click on the submit button" uttered in front of a course of 60 is the epitome of this issue. No web app copes with this with out-of-the-box configs -- that's why web apps are often "slashdotted".

In short: host with people who understand Moodle (hint: Moodle Partners!), or get someone really knowledgeable (hint again) to configure your server if you are hosting in-house. Moodle Partners not only know Moodle well, but also contribute (code, money) to Moodle.org which ensures the long-term viability of Moodle.
In reply to Art Lader

Re: Moodle is not really slow, is it?

by Patrick Blaine -
Moodle can be verrrrry slow depending on what shared space it's on.  Although we're moving to a dedicated server soon, we're still on our institution's shared space.  During times of high server traffic (the beginning of academic quarters) Moodle becomes almost unusable during peak times, and this from a gigabit connection.  If these problems happen at a very large university, I can imagine that a smaller institution with a weaker infrastructure could have even more problems.

This is not an issue with Moodle, however, but an issue of putting it in the wrong place.  Shared spaces that are designed/optimized for Moodle would present few problems.  It's just a resouce thing.  If you have a large installation that you want to run well, it can't be competing with a lot of other websites and installations. 
In reply to Art Lader

Re: Moodle is not really slow, is it?

by Martyn Overy -

Shared-hosting environment is a reasonable way of trying out the features and facilities of Moodle, without splashing out straight away on a dedicated server.  Moodle, however, is not slow! The hosting environment is an important consideration here...and you will not find many (any?) complaints originating from users hosted through Moodle.com. The definition and interpretation of 'slow' must be applied to the whole hosting environment, not individual software packages.

This thread might be relevant

In reply to Martyn Overy

Re: Moodle is not really slow, is it?

by Ger Tielemans -

We had someday a very slow Moodle: it turned out that in the header we had a wrong reference path added... (Had nothing to do with Moodle)

In the past I saw a tutorial for Lotus Domino: it did a query on a database that took an hour. Changing one line in that script and the same query took only one minute. (So is there a way to moitor the speed of several modules and blocks?)

In reply to Ger Tielemans

Re: Moodle is not really slow, is it?

by Martín Langhoff -
"Is there a way to monitor the speed of several modules and blocks?"

That's exactly what we do on our production servers. We monitor, log and give a score to slow database queries - we produce a "top 10" of those, and similarly with slow pages. Take a look at your database's "slow query log", and start playing with EXPLAIN and EXPLAIN ANALYZE to understand why a query is fast or slow.

I get these "top 10" emails every day in my inbox. I think the database queries are mostly sorted, though there's always new code coming in, and people use new modules and features that show up in the logs and we rush to fix them.

I'm now starting to measure memory footprint of pages as well -- I'll write a "top 10" script as well. If we can reduce memory footprint, Moodle's scalability will soar beyond where we are now (and we're in a pretty strong position).

Most reports of moodle running slow or apparently "crashing" under load are due to bad apache/mysql configs leading to consuming all the available memory.

There was a lot of work in 1.4.3/1.4.4 coming from what we learned in our production deployments. There's more coming in 1.5.

And yes, it's exactly the way you describe: a SQL query can be made a hundred times faster with a bit of tuning.
In reply to Art Lader

Re: Moodle is not really slow, is it?

by Martin Dougiamas -
Picture of Core developers Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers
"Moodle" is just the top layer of a complex set of systems, including software requirements like PHP, Database, Web Server, Operating system, PHP acceleration, caches and hardware requirements like CPU, RAM, disk space and bandwidth.  

All of these things (as well as other systems competing for these hardware resources) can cause slowdown or problems which are nothing to do with Moodle itself.  Even client systems like browsers can have a big impact on apparent performance.  Within Moodle are many optional features such as text filters that will create more work.

When we find performance issues that we can fix, using more efficient logic, data caching or indexing, then we do it, but otherwise the system administrator needs to look at these other systems.

I think Moodle compares very well with other software of a similar size and complexity.
In reply to Art Lader

Re: Moodle is not really slow, is it?

by Art Lader -

Thank you, everyone, for your posts. It is difficult for me to talk in an informed way about this stuff, because I just don't know anything at all about servers. I appreciate your taking the time to post such helpful responses.

This does, however, make me more hesitant than ever about even tryng to set up my own Moodle server. (Although I suppose Moodle for Windows is tweaked to achieve maximum performance.) But that's another issue, I suppose...

-- Art

In reply to Art Lader

Re: Moodle is not really slow, is it?

by Martín Langhoff -
I think you should go for it. smile

All the different Moodle installs have a place under the sun. Simple installs are great to start using Moodle, and perhaps use it with a handful of simultaneous users. If you're thinking of running with many simultaneous users, tuning is required. Just like with any other rich web app.

(Edit: Moodle for Windows is, as far as I know, tweaked for simplicity, not for performance. For multi-user performance, I recommend Linux/Unix).