SQL .db Size Limits

Re: SQL .db Size Limits

by Richard Lobb -
Number of replies: 0
When running a job with support files, CodeRunner first tries to send the job request to Jobe assuming the file is already in the Jobe file cache (which is usually the case as most files are question authors' support files, used repeatedly). If Jobe responds with a 404, an HTTP PUT is used to send the file to Jobe and the job is re-tried. However, if the PUT fails you get the error message above:

Jobe server request failed. One or more of the specified files is missing/unavailable.
In your case the PUT has almost certainly failed because of the file size rather than because there's no such file: the error message isn't very helpful in this case, I admit.

You're into a very messy space here because there are just so many different parameters that you might be running foul of, on either the Moodle server or the Jobe server.

On my development environment, I tried running a CodeRunner question with a 95 MB file and it failed with the error message

Fatal error: Allowed memory size of 268435456 bytes exhausted (tried to allocate 127291392 bytes) in /var/www/html/moodle/question/type/coderunner/classes/jobesandbox.php on line 296

On a production server you wouldn't see such errors because they're hidden from users. Note that although the file is only 95 MB, it's needing 268MB of memory to process it (it has to be Base64 encoded for one thing). This error is on the Moodle server, not the Jobe server.

Pinning down exactly what limit you're running into would take some time. But then, having done so, you'd have to persuade the appropriate system administrator to increase the limit just for your question. The larger one makes these limits, the greater the risk of resource depletion or denial of service attacks. So you might have trouble convincing the sysadmin.

My recommendation is that you find a way to achieve the same learning outcome with smaller files :)

Richard