Backup Moodle Site Without User Data?

Backup Moodle Site Without User Data?

by Becka M -
Number of replies: 5

Is it possible to backup an entire Moodle installation, sans any user data?  (No users [except the admin], no grades, no quiz attempts, etc.)

I have a Moodle installation on my site already going, and I'm wanting to create a second, almost identical one.  However, I don't want to go through and manually make all the little settings changes in order for them to be the same.  I also don't want to copy over every individual course.

I also am not talking about a mirror site.  The second site would be a near duplicate of the first, but with a slightly different purpose and content.

Average of ratings: -
In reply to Becka M

Re: Backup Moodle Site Without User Data?

by Emma Richardson -
Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers

There is a great plugin called admin presets that will let you take all the settings from one site and import to another...

In reply to Emma Richardson

Re: Backup Moodle Site Without User Data?

by Becka M -

Thanks, Emma.


I've tried it, and it seems to do only part of the job I need.  I imported the settings from Site A into Site B, but there were still things missing.  Some things that didn't carry over: the theme setting I use; certain blocks (like an HTML block and its contents); activities on the Front Page...

In reply to Becka M

Re: Backup Moodle Site Without User Data?

by Emma Richardson -
Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers

It does import any content, just admin settings.  You might also look at flavors plugin - it will pull in some extra stuff but I am not sure it has any content either.

In reply to Becka M

Re: Backup Moodle Site Without User Data?

by Becka M -

Hmm... Here's a thought:

What if I copied over the entire installation --user data and all--, then reset all the courses, and then went into the database and deleted all but the admin, guest, and my dummy/tester accounts in the user table?

Would that do nearly the same thing, or are there other tables that would need to be cleared out?


In reply to Becka M

Re: Backup Moodle Site Without User Data?

by Emma Richardson -
Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Plugin developers

That would create a disaster - users have entries all over the database related to grades, enrollments, assignments, etc. etc..

If you want all your content, backup all your courses to a folder that is accessible from both moodle sites (repository of some sort works well).

Create your new site from scratch.  Use the upload courses feature to create new courses and use your course backups as templates - that will bring in all the content.  (Except for the front page that you will need to recreate but that shouldn't take long).

Average of ratings: Useful (1)