Usually, it's caused by some "illegal" characters added in the original course due to some copy/paste of text containing them (control characters, or invalid sequences...). The best method to handle this issue is: Unzip the problematic backup file under one empty folder. Open the moodle.xml with Firefox.
This has been known to be caused by older versions of libxml2 and PHP - try updating them to the latest versions. How can I extract original files from a Moodle backup file?
The .mbz backup file for courseid=25 will be stored in the backup subfolder in the Moodledata ($CFG->dataroot) folder. Lose content after a restore in Moodle 2.0 ?
c) In Moodle 3.0.3 onwards and for admin user conflicts only, enable the setting 'Allow admin conflict resolution' in Site admin > Courses > Backups > General import defaults. This will result in the username in the backup file being renamed to 'admin_xyz'.
In the Moodle source code folder have you got a folder in the mod folder called tiles? What does it contain?
I have tried looking everywhere to find the culprit that is messing up the site. I have turned debugging on and now I am getting this.
Try purging caches: under Site administration ▸ Development ▸ Purge caches click Purge all caches. Does that fix it?
Yes, I got rid of all the debugging messages by purging the caches, but whenever I try importing questions using the Aiken format, I get the error Invalid permissions detected when trying to create a directory. Turn debugging on for further details.
Well you can enable debugging and post details here (or in a new discussion if it's not related to this issue).
Did you get anywhere with the above about the lock only I have exactly the same issue. I too was thinking about installing a later version of Moodle in the hope that it took the issue away, but when I looked at the code in the above file it looked the same in both versions to me.
Ok. So , I reinstalled moodle once again. This time I try to upload a file using AIKEN format and I get a bit more info on the error.
To backup a course. Go into the course. Click the Backup link either in the gear menu or the Administration block (depending upon the theme). Initial settings - Select activities , blocks, filters and other items as required then click the Next button. Users with appropriate permissions, such as administrators and managers, ...
Note: With large courses it is helpful to be able to continue working while a course backup is being made. To achieve this, you need to enable asynchronous backups in Site Administration / Courses / Backups / Asynchronous backup/restore .
Course backup. A course can be saved with some or all of its parts by using the course backup. Typically, the site administrator will set a schedule of automated course backups for the whole site. A teacher can create a backup or download an existing backup for safe keeping, or for use on another Moodle site.
To backup a course. Go into the course. Click the Backup link either in the gear menu or the Administration block (depending upon the theme). Initial settings - Select activities , blocks, filters and other items as required then click the Next button. Users with appropriate permissions, such as administrators and managers, ...
Course backup. A course can be saved with some or all of its parts by using the course backup. Typically, the site administrator will set a schedule of automated course backups for the whole site. A teacher can create a backup or download an existing backup for safe keeping, or for use on another Moodle site.
Site backups are recommended in order to have all data saved with the best confidence and the shortest recovery time.
This is an intentional design decision. Because of the way files are stored in Moodle 2.x, there is no need to include the files in the backup if you are planning to restore them to the same Moodle site. Leaving them out saves huge amounts of disk space and makes the backup procedure much faster.
By selecting all the options when setting up the backup you can include almost all the data in the course. However you should be aware of the fact that some things are not backed up:
In Site administration > Courses > Backups > General backup defaults, there is a setting for "Include logs." By default, this is off.
In Site administration > Courses > Backups > General backup defaults, there is a setting for "Include histories." By default, this is off.
See Backup via CLI in Course backup and Restore via CLI in Course restore (new in 3.10 onwards).
This part of the backup (or restore) procedure tries to delete old info, used in previous executions, performing the following tasks:
Anonymize user information is a backup feature which "protects user identities" by making each user anonymous. If this box is checked in the backup initial settings, Moodle will substitute aliases for real names, substituting @doesntexist.com email addresses and so forth. For example "Max Manager" might become "anonfirstname4 anonlastname4".
Courses created in 1.9 can be backed up and then restored into a 2.1 Moodle or later but blocks are not currently restored and nor is user data (such as forum posts, grades, submissions etc).
The assignment activity module was completely rewritten in Moodle 2.3. Thus, assignments from Moodle 2.2 and older (e.g. from Moodle 1.9) need to be upgraded in order to continue being usable. See the section 'Restoring course backups from Moodle 2.2 and older' in Assignment upgrade tool for details of what to do.
Lose content after a restore in Moodle 2.0 ? Do you see topic headings that say "Orphaned activities"? Solution: Go to course settings and increase the number of topic sections and things will return to normal.
The backup and restore processes can offer the teacher and administrators many creative solutions.
Default settings for course backups can be set by a site administrator in Settings > Site administration > Courses > Backups > General backup defaults .