Exporting/backing up whole database (including entries and files which were uploaded into database)

Exporting/backing up whole database (including entries and files which were uploaded into database)

by dom nerus -
Number of replies: 5
Is it possible at all.

Because when I backup database or import into the new course, I only get database structure, but not the entries or the files which were into original database.

Thank you


Average of ratings: -
In reply to dom nerus

Re: Exporting/backing up whole database (including entries and files which were uploaded into database)

by Itamar Tzadok -

If you backup/restore with user info you should get the entries and files. smile

In reply to Itamar Tzadok

Re: Exporting/backing up whole database (including entries and files which were uploaded into database)

by Helen Foster -
Picture of Core developers Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators

Another option is to export then import all of your entries. Please see the documentation Using Database for more details.

In reply to Helen Foster

Re: Exporting/backing up whole database (including entries and files which were uploaded into database)

by Catherine Mclean -

I've just been trying to get a copy of a database (entries included). I has (wrongly) assumed that duplicating the database would suffice. It clearly did not. So the word 'duplicate' does not relate here. 

Then I tried importing the database into the same course - this did not work. 

Then I tried backing up the database and restoring it into the same course. Thankfully this worked but why should it take a backup and restore of a database to get a copy of it? Surely duplicating (making a copy) of the database should suffice? 

If the academic in charge of this particular Moodle course is a low confidence user, they will panic if they know they've got to backup and restore a database every time they want to make a copy of it. 

In reply to Catherine Mclean

Re: Exporting/backing up whole database (including entries and files which were uploaded into database)

by Itamar Tzadok -

As a matter of fact the duplicate option does backup/restore but without user data. So it's really just terminology. Still I agree that it may be somewhat intimidating for some. This may be a viable usability issue with respect to all modules and it may be worthwhile to open a tracker issue for it if not already exists. smile

In reply to Catherine Mclean

Re: Exporting/backing up whole database (including entries and files which were uploaded into database)

by William Lu -
Picture of Particularly helpful Moodlers
I like the way of Moodle Duplicating an activity without any user date.

When I duplicate an activity in the same course, most of time, I want a fresh start for another week or section. If it includes user date, I might need to spend time to clean it up manually.

When I want to use the same activity in another course, I can import or backup/restore with user data.