Error writing to database Moodle 2.6

Re: Error writing to database Moodle 2.6

by Ken Task -
Number of replies: 2
Picture of Particularly helpful Moodlers

All those variables have to do with PHP.   If your development environment (local Winders install) NOT the same as production (remotely hosted on a shared plan running Linux), then really no sense in comparing apples to oranges.  Is production environment on shared hosting or dedicated?  Could be chasing wrong rabbit! smile  Yes, turning on debug is good advice.   Before doing that, however, check server logs: mysql error log or apache error log.  They often give clues as to issue.  As far as cron ... where, specifically, does it fail?  Start of running it?  In middle? towards end?  Don't have to answer the questions posted here ... consider them food for thought, unless you need further assistance.

'spirit of sharing', Ken

In reply to Ken Task

Re: Error writing to database Moodle 2.6

by Gordon Toudt -

Having a similar issue.  2.6.4 PHP and Apache at specs... Development works fine but production box same settings will not work correctly.  We get the "Error writing to database"  at various points  but most common is restores, editing a question, also cannot upgrade assignments or questions for some but some did write tot he database and upgraded.  Just brought all of this in from MoodleRooms and they are not willing to assist.  The database has 522 plugins it cannot find "missing from disk".   We asked them to remove all of their plugins prior to sending us the data.  they did not.  suggestions on how to fix this.  Assign mod plugin also will not create a working assignment but old assignments will work.  very confused at this point.


 i will send you my PHP settings Info but cannot attach it here.

gordon.toudt@ucps.k12.nc.us I will send it


In reply to Gordon Toudt

Re: Error writing to database Moodle 2.6

by Ken Task -
Picture of Particularly helpful Moodlers

Basically, you are asking 'how to clean up a moodlerooms site that has been migrated to an internal server' ... which is something very few folks have done.  It is not something one could describe in forums ... not a 1-2-3 thing at all.  Much has to be explored and discovered ... then what approach to take to eradicate moodlerooms from the site.

Isn't that a shame ... moodlerooms not removing their addons/extras before providing you a copy of your files!!!!   One thing for sure, your entity won't be going back to MR, right?

Anyway, have just finished eradicating Remote Learner stuff from a Moodle brought back inside the entity.   Same thing there ... RL not helpful.   Eradication required some manual manipulation of the DB tables.  And, had to work on a hidden Apache Virtual server that was on the same production server (to be in the same environment) - basically a 'mirror' of the production site - minus it's own data directory as the production server didn't have enough space to replicate that to the 'sandbox'.   Working strictly in the 'sandbox' code and DB with NO file uploads or anything that might stick 'orphaned files' into filedir managed to rid the 'sandbox' of anything RL.   Then, it was a matter of timing ... move what I had done in the sandbox back to the production site without loosing too much of the new work etc. that had been done on the production site that was still being used while work was being done on the sandbox.

Can be done with MR as well, I would imagine, but it would require not only access to moodle Admin but also command line and direct access to the DB.  And it would take time ... probably longer than you have, right? 

You can find my 'regular' EMail address in my profile if you'd like to discuss/cuss OFF this list/forum.

'spirit of sharing', Ken