Moodle hangup when opening multiple pages

Moodle hangup when opening multiple pages

by David Camacho Cateura -
Number of replies: 5

Dears,

I have worked with Moodle for a few years now, but on a basic level. I have been able to solve all minor and major problems that have affected our moodle up until now. 

Up until March, when we were forced to stop activity due to the coronavirus, our moodle performed well. It was not that fast, but it was reliable and we faced very few problems. 

Since March, nobody has used the Moodle. All accounts were suspended and I was the only person with access to it, as the administrator. I have not done any change. 

However, when accessing the Moodle again to prepare the new course, I found that it constantly hangs up. Fool of me, every time I thought I had found something that would be the cause, I opened multiple pages to see if they loaded or not. The first two or three tabs load correctly, but after from that tab onwards, it does not load. When this happens, I cannot access any moodle page from any device. After two or three minutes, it works again.

I have tried purging all the caches, disabling everything that may affect performance and many other possible solutions that I found in this forum regarding performance. When the moodle is working, the speed has significantly increased. However, it still hangs up when doing multiple things.  

I am perfectly aware that it may not be a problem of the moodle, but the server. However, I have another functional moodle hosted in the same server, with exactly the same configuration as this one (I have checked everything) and I don't face this problem in there. I have tried the two tools mentioned in the Profiling wiki, but I think that my hosting service does not allow me to install them. 

We do not have any "special" cache systems enabled, but we did not have them in March, neither. 

Moodle versions: At the beginning of the problem I was at 3.5, tried updating to solve it and I am now at 3.9

Hosting service: Strato, with their "Professional Hosting". Databases are MySql 5.6. Php version is 7.3 (although I have tried 7.2 and 7.4 with no success). I have tried PHP boost on and off (AH0125 and FastCGI)

This is the "Network" tab of the Chrome developer console when the moodle is hanged up. Link

The strato error registry shows these errors (among others)

19.09.2020 11:23:51  [client 5.224.86.0] AH01215: : couldn't get boot time: Permission denied: (omitted)/admin/tool/monitor/managerules.php

19.09.2020 11:24:04 [client 5.224.86.0] AH01215: /usr/bin/uptime: (omitted)/admin/tool/spamcleaner/index.php

19.09.2020 11:24:04 [client 5.224.86.0] AH01215: : couldn't get boot time: Permission denied: (omitted)/admin/tool/spamcleaner/index.php

19.09.2020 11:24:20  [client 5.224.86.0] AH01215: /usr/bin/uptime: (omitted)/admin/category.php

19.09.2020 11:24:20  [client 5.224.86.0] AH01215: : couldn't get boot time: Permission denied: (omitted)/admin/category.php

19.09.2020 11:35:40  [client 114.119.2.0] rdbmmap (24):  DENY on request rate

19.09.2020 11:35:40  [client 114.119.2.0] rdbmmap (24): DENY on request rate

19.09.2020 11:35:44 [client 5.224.86.0] End of script output before headers: view.php

19.09.2020 11:36:00  [client 5.224.86.0] End of script output before headers: view.php

19.09.2020 11:36:25  [client 5.224.86.0] End of script output before headers: service.php

19.09.2020 11:38:35  [client 5.224.86.0] End of script output before headers: service.php

Do you have any kind of suggestion on what I should work on? Thank you a lot!



Average of ratings: -
In reply to David Camacho Cateura

Re: Moodle hangup when opening multiple pages

by Ken Task -
Picture of Particularly helpful Moodlers

Dunno what 'PHP boost on and off (AH0125 and FastCGI)' means.

Is 'boost' php-opcache by another name?  Or something special offered by provider?

Are your sites on a dedicated server ... no other customers on same machine? ('Professional' could also apply to shared services)

The AH0125 looks like an Apache error related to cgi.

Not all hosting providers do things the same way - that to say Strato helpdesk might be in order.

Understand security issues ... but the 'omitted' might have provide a clue ... if for example omitted was a path ... /home/[useraccount]/[domain]/public_html/  or just /home/[useraccount]/public_html/ isn't the same as /var/www/html/

Ownerships/permissions on folders/files ... upgrading code won't fix those issues although kinda surprise you were able to upgrade.

"errors (among others)" ... like what?

Don't host with Strato so am asking dumb questions!

'SoS', Ken


Average of ratings: Useful (1)
In reply to Ken Task

Re: Moodle hangup when opening multiple pages

by David Camacho Cateura -
Thank you for your answer!

As defined by Strato, "PHP Boost activates a code cache with which your PHP scripts will execute a 100% faster". When it is activated , in the error messages appears
FastCGI. When it is not activated, AH0125 appears.

Regarding if it is a dedicated or shared server, it is shared.

"The AH0125 looks like an Apache error related to cgi." Is there any way to confirm or check this? Past experiences with the Strato helpdesk have not provided much help, but I will give that a try on Monday.

The path was as follows: "/home/strato/http/premium/rid/XX/XX/XXXXXXXX/htdocs/moodle/", where X are random numbers.

I upgraded the code before finding those errors, I am also quite surprised that it allowed me to. However, when doing one thing at a time, the moodle works. It is when multiple things are asked (as opening 10 pages in one second) that the server hangs up during some minutes.

With "among others" I meant that these errors keep repeating every time it hangs up. The only thing that changes is the end of the message (i.e. managerules.php, index.php, category.php, delete.php...)

Thank you again for your time, I really appreciate it. 
In reply to David Camacho Cateura

Re: Moodle hangup when opening multiple pages

by Ken Task -
Picture of Particularly helpful Moodlers

Their PHP 'boost' is like php-opcache or an accelerator.  Could be conflict between highly recommended php-opcache and this 'boost'.

In both moodles, go to Admin Server Environment check to see if there's anything Moodle might be complaining about.    Also Admin Server PHP info link might show caps or limits.   

If helpdesk should be able to tell you about AH0125 errors ... after all it's shared hosting - you don't config anything about web service.   You don't have much control over resources of that server (if any).    What they won't do ... and most don't ... is get into the config of applications customers choose to run ... ie, Moodle.  And before you ask, no not much one can do with core code of Moodle to make up for restrictions imposed on shared customers.

Shared hosting  - 2 Moodle sites ... can only guess that the one instance that doesn't have issues probably isn't used as much.

Also, see that Strato offers what they call AppWizard ... is that how you've installed the moodles and did the upgrade of the one site?

I see by https://www.strato-hosting.co.uk/hosting/ there are no specs of what one gets.

You might inquire about a path from shared hosting to a managed (they do heavy lifting) or un-managed (you do heavy lifting [admin of server]).

'SoS', Ken

Average of ratings: Useful (1)
In reply to David Camacho Cateura

Re: Moodle hangup when opening multiple pages

by Guillermo Dova -
That seems to be a ModSecurity filter in action https://en.wikipedia.org/wiki/ModSecurity
Maybe you can ask support if its enabled and if any filter has been activated, they will need the IP of the PC where you are browsing.

Shared hosting plans are generally limited and may not compatible with moodle requirements.
Average of ratings: Useful (2)
In reply to David Camacho Cateura

Re: Moodle hangup when opening multiple pages

by David Camacho Cateura -

After contacting with Strato and being of literally zero help, I ended up migrating the moodle to Hostinger. 100% problem-free. 

Thank you a lot for your time.