Moodle

Backup cron errors on some courses / course restore error

Details

  • Type: Bug Bug
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Not a bug
  • Affects Version/s: 1.8
  • Fix Version/s: None
  • Component/s: Backup
  • Labels:
    None
  • Affected Branches:
    MOODLE_18_STABLE

Description

I have some courses that fail backup. I think it might be because they imported the course from a different version of Moodle or some other user error but I think it should be prevented. I end up with entries in the mdl_course_sections table that don't correspond to existing resources. They show up in the course as a module logo with no title. The resource can't be deleted because it doesn't actually exist. So the only way to get rid of it is manually from the database.

This problem doesn't cause the backup to fail...but another problem in the database does. I search the mdl_course_modules table for instanceid=0 and I get 1 record for that course. I have to delete this record before the backup will work again.

1. What is causing this database issue.

2. Should there be some kind of resource validation before a link is created or a resource is imported?

Issue Links

Activity

Hide
Dan Marsden added a comment -

Hi Matthew,

can you please turn debugging on for your site, and post any errors that display during the backup/restore here?

thanks,

Dan

Show
Dan Marsden added a comment - Hi Matthew, can you please turn debugging on for your site, and post any errors that display during the backup/restore here? thanks, Dan
Hide
Matthew Davidson added a comment -

Request to close.....

Show
Matthew Davidson added a comment - Request to close.....
Hide
Dan Marsden added a comment -

done. - thanks!

Show
Dan Marsden added a comment - done. - thanks!

People

Vote (0)
Watch (1)

Dates

  • Created:
    Updated:
    Resolved: