error/invalidrestorefile Errors Trying to Restore a Course in Moodle

I am running Moodle 3.1 (Build: 20160609); however, none of that matters.  I had errors restoring files as I reset my system for the next academic year which I do immediately before they send me packing for the summer season. 

I got it to work last Friday but on Monday decided to start again from scratch and ran into the problem again and the forums simply didn’t help me.

Both last Friday and Monday, with a fresh install and database I had the eror ‘error/invalidrestorefile’ crop up when attempting to restore backups files from a Server File Repository I had created on the server.  I tried all the suggestions in the folder, but so many seemed to end with “that fixed it” when the resolution should not have.  

The trick to solving this is to see the patterns in the postings on http://moodle.org.  Most “magically” solved the problem and couldn’t really give developers any explanation.

It doesn’t restore from the respository, not with “Import a backup file”, it appears to run into the 2MB limit and yet returns ‘error/invalidfilerestore’.  I did grin at the person who deleted PDFs, delete what you will, when you are under 2MB it works.   UNLESS, you simply waltz into the Front Page Restore and ADD the file to the backup location.  Yup, on the page below I was selecting the “Import a backup file” location when I needed to click on “Manage course backup area” [it also works in “User private backup area”], then select the Moodle “copy” to copy the file from the Repository to the appropriate backup area and THEN it restores just fine.

Whew!  Somedays I should have more coffee and click less.

Moodle File Restore