.xslx/.ods quiz report downloads

.xslx/.ods quiz report downloads

by Kelvin Desmoyers-Davis -
Number of replies: 3

Hello,

My first time posting here, sorry if this is the wrong area for these sort of discussions and can repost in a different area if required. Hoping someone in the community might be able to help us with a issue on our Totara quiz report downloads. 

When we download table data as .xslx or .ods in Chrome browser:




we see the following (HTTP 500)


(This site can’t be reached. The web page at https://{FQDN.here}./mod/quiz/report.php?sesskey=5FwahJsi9Z&download=excel&id=176&mode=responses&attempts=enrolled_with&onlygraded=&qtext=0&resp=1&right=0 might be temporarily down or it may have moved permanently to a new web address ERR_INVALID_RESPONSE)


The file actually still downloads (size < 3MB) just the page fails to load correctly. If we download table data as .html, .csv, or .json we do not get this site can't be reached error.  


Site is running on an x64 Windows Azure app service, PHP 7.3.29, Totara 12.12 (Build: 20191126.00)


Hope someone can steer us in the right direction! Thanks

Average of ratings: -
In reply to Kelvin Desmoyers-Davis

Re: .xslx/.ods quiz report downloads

by Tim Hunt -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers
Do you have a CDN or revers proxy in front of your Moodle site?

We recently started using CloudFront, and we hit problems with some reports, because CloudFront gives up if a page (or download) takes more than 30 seconds. You say you are on Azure, so it is quite likely there is a web caching layer in there which is doing something similar.

To see if this is the problem, try opening the Developer tools in your browser, and looking at the Network information. If the request is stopping after a certain amount of time like 30s or 60s, and it is always the same, this is probably what is going on.
In reply to Tim Hunt

Re: .xslx/.ods quiz report downloads

by Kelvin Desmoyers-Davis -
Hi Tim,

Thanks for the response, there is a CDN, from the infrastructure side it looks okay. Is there any specific CDN configuration in Moodle? i.e. some PHP config files?

What's odd is the environment is deployed via IaC pipeline (ARM templates for the infra, some site config) and we have another identical environment (same CDN configuration) and we do not see this behaviour on the other environment. 

In Dev tools we see the following:




the '(failed)' is a HTTP 500 error which usually happens after around 10 seconds from downloading the .xlsx/ods report. Then after around 20 seconds (the last HTTP 200 on the screenshot) the file downloads!
In reply to Kelvin Desmoyers-Davis

Re: .xslx/.ods quiz report downloads

by Tim Hunt -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers
That is weird. Sorry, I don't really have any useful advice to give.