beginner backup queries

beginner backup queries

Jenny Toller -
回帖数:8

I am having a bit of a problem understanding the backup documentation and I would be most grateful for any advice. I have several queries:

Automated backups and site backups:
Do most people use both methods in conjunction or just site backups?

Automated backups:
For the time to be executed, do you set your local time (given that I have set the timezone in Configuration - Variables - Interface) or the server time?

Automated backups:
In the documentation it says

In order to make scheduled course backups, you have to setup CRON to run periodically.

I don't understand this - I thought that automated meant automated! Or is this an additional method if you want to set up a more complex schedule of backups?

Site backups:
I thought that I would look at the MySQL Admin module for the database part of this, assuming that it can be automated. However, it indicates that this is for Moodle version 1.5. Does anyone know if I can also use it for 1.6?

Many thanks for any help smile

Jenny

回复Jenny Toller

Re: beginner backup queries

Paolo Oprandi -
Hi Jenny,

Automated backups and site backups:

Do most people use both methods in conjunction or just site backups?

Just automated backups. They do the whole site while , i believe, site backup just does the front page.

Automated backups:
For the time to be executed, do you set your local time (given that I have set the timezone in Configuration - Variables - Interface) or the server time?

depends if your server is running the right time. 

Automated
 backups:

In the documentation it says
In order to make scheduled course backups, you have to setup CRON to run periodically.

I don't understand this - I thought that automated meant automated! Or is this an additional method if you want to set up a more complex schedule of backups?

Automated if you set up the cron (well, that is apache configuration). I should read the documentation and contact your server admin about this.

Site backups:
I thought that I would look at the MySQL Admin module for the database part of this, assuming that it can be automated. However, it indicates that this is for Moodle version 1.5. Does anyone know if I can also use it for 1.6?

I don't know anything about this, but you could just install phpmyadmin which will work on any version (or any application).

Hope that is slightly useful, Paolo
回复Paolo Oprandi

Re: beginner backup queries

Jenny Toller -
Thanks, Paolo but, in truth, I am as confused as ever...  blush

I have read the documentation - many times! - and maybe I am understanding it all wrong (this is very likely) but there seems to be 2 ways of backing up data:
  1. automated course backups (set up via Admin - Configuration - Backup)
  2. (whole?) site backups as detailed on the upgrading Moodle page (including config.php, customised files, data directory and database)
The documentation clearly states that site backups are recommended and preferable (and I will work out how to do this) but I was also wondering whether it was a good idea to do course backups as well. I was surprised to hear that site backups are for the front page only - this sounds most odd!

From an administrator's point of view, the backup configuration page certainly gives the impression that everything will be automated - and I read nothing in Jason Cole's book to disprove this. Therefore, I was confused when I read in the documentation about using a cron in conjunction with these automated backups: it was not at all clear to me that it was essential to set this up.

I have set up a cron for forum posts etc. and this works well but I could not see any suggestions on the cron page about what sort of commands I would need to input for the automated backups. And this is also where the server time comes in...

Yes, the server time is set correctly but it is in a different time zone - 5hrs difference. Obviously, I use server time on a cron but hence my uncertainty with the admin configuration backup page setting as to whether I should use local time or not.

Our Moodle site is hosted and I am sure the hosting company will advise if I get really stuck but I need to do as much as I can myself.

Cheers,

Jenny
回复Jenny Toller

Re: beginner backup queries

Paolo Oprandi -
Yes, sorry, I will have confused you.  The backup link on the front page only backs up the front page (and actually that is not the site backup that you mentioned).

Basically, the scheduled backup will backup course-by-course and to restore your site via this method you would have to restore course-by-course in a timely procedure.  The site backup method will backup the whole site and if it breaks you will be able to resurrect your whole site using the method described. 
回复Paolo Oprandi

Re: beginner backup queries

Jenny Toller -
Thanks smile
LOL, I hadn't even noticed the backup link on the front page...! I only installed Moodle recently and am working through everything 'from the top'. So, I have barely had a play with anything yet as I am saving the fun stuff for later on. wink

I have spent the past couple of hours reading some very old backup/restore threads and I think that I am now just beginning to 'get' it. (Is it just me, or does the backup documentation lack clarity?) Anyway, I think that I can now answer my own questions:

Yes: do both types of backups. (I'll tackle the MySQL dump later.)

Automated course backups configuration execution time: use local time

Cron: I think that I have already done this (same cron command is used as that added during Moodle installation - yes? - I originally assumed that additional commands would be required)

Cheers,

Jenny
回复Jenny Toller

Re: beginner backup queries

Paolo Oprandi -
I don't think the cron for site backups is included in cron.php. I think you need to run the cron script suggested.
Cheers, Paolo

回复Paolo Oprandi

Re: beginner backup queries

Jenny Toller -
Oh dear, I thought that I was running the cron script - I created a cron.txt as described on the cron page at the end of the installation process (and it works fine). Will this one not also serve for the automated course backups? My reading of the forums this afternoon suggested that it would. I appreciate that the site backups are another thing altogether but I thought that I would get the course backups up-and-running first. I'll see what happens tonight  wide eyes

Thanks for your help,
Jenny
回复Jenny Toller

Re: beginner backup queries

Paolo Oprandi -
Sorry. I am not being very helpful... if it works, continue with what you are doing! Make sure you can do the restores that you expected from the resulting backups.
回复Paolo Oprandi

Re: beginner backup queries

Jenny Toller -
Oh, I now realise that we were communicating at cross purposes  wink
My automated course backups work fine and I will be experimenting with restoring them today. Then on to tackle site backups!
Cheers and thanks,
Jenny