can't connect to our server unless purging all cache every day

can't connect to our server unless purging all cache every day

by Katriel Lerner -
Number of replies: 6

We are using Moodle 3.1.3 version

We developed a different GUI which connects to Moodle using SAML. We have our system installed and working on Windows and Linux Ubuntu servers for testing.

We got the system to work on another Linux Ubuntu server which is behind a load-balancer with SSL, but everyday we get an error screen from server of empty response. It seems that something is locked.

When connecting to Moodle's GUI as administrator and purging all cache, our system is working again.

Just to clarify: the "Use HTTPS for logins" is disabled in the HTTP Security config of Moodle.

Can someone help us understand what can cause this problem?

Can it be right to leave this as is and run a cron that will purge the cache every morning? To me it doesn't seem correct but I can't find the reason why the cache could cause this daily.

Average of ratings: -
In reply to Katriel Lerner

Re: can't connect to our server unless purging all cache every day

by Matteo Scaramuccia -
Picture of Core developers Picture of Peer reviewers Picture of Plugin developers

Hi Katriel,
does the empty response (WSOD) come straight from Moodle or from the Load Balancer?

You could enable the Moodle debugging at DEVELOPER level to look for an error message if the WSOD comes from Moodle.

How are Moodle sessions managed? Using file system or DB store?

HTH,
Matteo

In reply to Matteo Scaramuccia

Re: can't connect to our server unless purging all cache every day

by Katriel Lerner -
Hi Matteo,



Thanks for the fast response.

How can I check from where came the empty response?

Where do I find the Moodle log? I think that the debugging is on.



Have a nice day,

Kathriel
In reply to Katriel Lerner

Re: can't connect to our server unless purging all cache every day

by Matteo Scaramuccia -
Picture of Core developers Picture of Peer reviewers Picture of Plugin developers

Hi Katriel,

Where do I find the Moodle log? I think that the debugging is on.

I'd check since that setting should not be there in Production and it could display the error message directly in your display (pretty almost the time, some strange errors will be written into the PHP error log, depending on your nodes' configuration): https://docs.moodle.org/31/en/Debugging#Debug_messages and https://docs.moodle.org/31/en/Debugging#Display_debug_messages

HTH,
Matteo

 

In reply to Matteo Scaramuccia

Re: can't connect to our server unless purging all cache every day

by Katriel Lerner -
Hi Matteo,



Thanks again.

The debugging is on because the system is not in use yet.

We are in the middle of preparing it for production.



What I get is an error of empty page from the server.

Does that mean it isn't a Moodle error?



Why does the cache purging help?



When it happens, it looks like any page of our system which is shown from

the domain is locked. As I mentioned, Moodle pages are open.



Doesn't Moodle have a log file somewhere?



Thanks,

Kathriel

בתאריך 14 בפבר׳ 2018 04:19 PM,‏ "Matteo Scaramuccia (via Moodle.org)" <
In reply to Katriel Lerner

Re: can't connect to our server unless purging all cache every day

by Matteo Scaramuccia -
Picture of Core developers Picture of Peer reviewers Picture of Plugin developers

Hi Katriel,
Moodle doesn't have a log file by its own but logs any "trappable" error in the standard PHP error log file as reported e.g. by Site administration > Server > PHP info: search for error_log in that table.

HTH,
Matteo

In reply to Matteo Scaramuccia

Re: can't connect to our server unless purging all cache every day

by Katriel Lerner -
Hi Matteo,



Thanks again for your kindly help.



I saw that we tried to enable the log from our code, but it did not get

there.



I added the needed flags in the php.ini



and found the log of the error. It is:



*PHP Fatal error:  Cannot run code from this file in conjunction with non

encoded files in ... on line 9, referer: ...*



I tried to find what causes this error but I'm not sure.



I understand that it relates to the Zend Guard we use. I saw that people

said it related to conflict between Zend and APC. but I didn't find any APC

used inour server.



Another option which sound much more relevant was some conflict between

Zend sessions and the Moodle sessions we used. I didn't find how I can fix

it.



The only solution I think we can use is to add purging of all Moodle cache

everyday by using cron.



Maybe you have an additional idea?



Have a nice day,



Kathriel







בתאריך 14 בפבר׳ 2018 19:11,‏ "Matteo Scaramuccia (via Moodle.org)" <