To set up the backup schedule for your Moodle site, follow these steps:

  1. Go to Administration > Site administration > Courses > Backups > Automated backup setup.
  2. Enable backup_auto_active.
  3. Select the days of the week when you want the backup to run.
  4. Set the execution time for the backup process. It is recommended to schedule it in the early morning according to your server's time zone.
  5. Choose a backup path. If possible, choose a backup path on another machine or a different drive than the one where Moodle is installed. Leaving this field blank will save backup zip files in the backup folder of each course files folder. On a Linux server, the path might look like: /home/(your user or domain)/public_html/archive/ or /home/(your user or domain)/archive/ if below the publicly accessible folders. On Windows, the path might look like: D:\Archive\.
  6. Set all other options appropriately.
  7. Click the "Save changes" button.

To save disk space, you can choose to delete backups older than a specified number of days. If you select this option, specify a minimum number of backups to keep. These options are available in Moodle 3.0 onwards.

Once you've set up your backup schedule, Moodle will automatically create archives of all the courses on the server at the time you specified. Once the backup is complete, an email will be sent to you describing the status of the backup.