Backup and restore

Error Creating Sections when trying to restore

 
Picture of Steve Blackwell
Error Creating Sections when trying to restore
 

I have struck a problem after deleting a course and then trying to create a new course. After setting the Teacher for the course I tried to enter the new course to get the message

Error finding or creating section structures for this course

No problems, I had a backup from the day before so I tried a restore.

On trying to restore I receive the following message: (it doesn't matter if I select New Course, Existing Course Deleting or Existing Course Add)

  • Creating new course
    • Literacy and Numeracy Online Community copy 1 (LANOC-1)
    • Category: Miscellaneous
  • Creating sections

    Error creating sections in the existing course.


An error has occurred and the restore could not be completed!

Now my main page has lost all of the items from the main menu. My back up file appears to be OK.

Users are still intact and I can add and delete users.

I can not add new modules getting the message

Could not add the new course module to that section

Moodle is running on a Windows 2K box and can be accessed at http://delta.pembrokesc.vic.edu.au

Is it time to re-install Moodle from scratch?

 
Average of ratings: -
One poor developer...
Re: Error Creating Sections when trying to restore
Core developersDocumentation writersMoodle HQPlugin developersTesters
Hi Steve,

it seems to be some problem in your instalation (DB become corrupted, perhaps...). All the errors showed in your previous post are relationated with the mdl_course_sections table, I think. The system isn't able to select or insert data in that table.

First of all you should check your db status, repairing corrupted tables(phpmyadmin, perhaps) if possible.

If this doesn't solve your problem, then you could try to restore the "problematic" table selectively (if you have a working backup of it).

Finally, you should reinstall everything, from db and moodle_data backups if you have them or reinstalling Moodle from scratch.

Hope this comments help, ciao smile



 
Average of ratings: -
Picture of Steve Blackwell
SOLVED!!!
 

G'day Eloy

Thank you for your help - it was spot on! The mdl_course_sections table was corrupt and couldn't be read.

For any one else with similar problems here is how (with Eloy's help) I fixed it.

I downloaded and installed mySQL's Control Center which made it easy to work with my database (it was similar to MS SQL's admin package which I was familiar with).

I deleted the corrupt table (I couldn't edit it) and created a new one with the same name.

I opened myql.sql from the lib/db folder into an editing package (I used Programmers Notepad). This gave me the structure of the deleted table.

I manually entered the fields for the table and saved.

Voila! Moodle was back in action.

My backups now worked (although I had to restore twice to get all of the content).

Support for Moodle is VERY impressive. Thanks again.

 
Average of ratings: -