notes-20160812: Exporting material from Moodle and importing it into Canvas

Exporting material from Moodle and importing it into Canvas

For getting the files from your moodle in Canvas:

Do a backup of the moddle course - producing a x.mbz file, then

cp x.mbz x.zip

mkdir Moodle_backup

mkdir Moodle_copy

cd Moodle_backup

unzip ../x.zip

../mbz-manipulate.py

wait  ... it will file Moodle_copy with a set of files - the directory names are based upon the context id, Moodle_copy can be used instead of the "files" directory in Moodle_backup.

If you move Moodle_copy into where files was, then zip the Moodle_backup directory, you can import the whole zip file into a course in Canvas.

The program (mbz-manipulate.py) could be improved, but I do not know how to interpret the contextid or other part of the file into something more useful (like a real directory name). There is probably some better directory organization to use than these context IDs. To prevent duplicate file names I just append a counter if the file already exists. 


If one does not want to move student content, then one can follow the directions at I also found that one can migrate course content, leaving out the student submissions according to the description at:
https://itconnect.uw.edu/learn/tools/canvas/canvas-help-for-instructors/getting-started/import-from-moodle/ Links to an external site.

2016.08.17 - version 2 of the program is mbz-manipulate2.py