Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-33812

backup_auto_keep not being honoured

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: 2.1.6, 2.2.4, 2.3.1, 2.4
    • Fix Version/s: 2.2.5, 2.3.2
    • Component/s: Backup
    • Labels:
    • Environment:
      Debian GNU/Linux (Squeeze), PostgreSQL 8.4.12, PHP 5.3.3
    • Database:
      PostgreSQL
    • Testing Instructions:
      Hide

      Test prerequisites

      (The followings are found in Home ► Site administration ► Courses ► Backups ► Automated backup setup)

      • Enable automated backups (backup_auto_active)
      • Set backup_auto_storage to 'Course backup filearea and the specified directory'
      • Set backup_auto_destination to some writeable path on your machine
      • Set backup_auto_keep to 2
      • Tick backup_shortname
      • Have at least two courses in your installation of Moodle

      Test 1

      1. Run `php admin/cli/automated_backups.php`
      2. Wait 2 minutes
      3. Run again `php admin/cli/automated_backups.php`
      4. Wait 2 minutes
      5. Run again again `php admin/cli/automated_backups.php`
      6. Wait 2 minutes
      7. Make sure you don't have more than two backups of each course in backup_auto_destination
      8. Go to Home ► Courses ► Champion ► Restore
      9. Make sure you don't have more than two backups under 'Automated backups'

      Test 2

      1. Set backup_shortname to false (untick)
      2. Keep any existing backup
      3. Repeat test 1
      Show
      Test prerequisites (The followings are found in Home ► Site administration ► Courses ► Backups ► Automated backup setup) Enable automated backups ( backup_auto_active ) Set backup_auto_storage to 'Course backup filearea and the specified directory' Set backup_auto_destination to some writeable path on your machine Set backup_auto_keep to 2 Tick backup_shortname Have at least two courses in your installation of Moodle Test 1 Run `php admin/cli/automated_backups.php` Wait 2 minutes Run again `php admin/cli/automated_backups.php` Wait 2 minutes Run again again `php admin/cli/automated_backups.php` Wait 2 minutes Make sure you don't have more than two backups of each course in backup_auto_destination Go to Home ► Courses ► Champion ► Restore Make sure you don't have more than two backups under 'Automated backups' Test 2 Set backup_shortname to false (untick) Keep any existing backup Repeat test 1
    • Affected Branches:
      MOODLE_21_STABLE, MOODLE_22_STABLE, MOODLE_23_STABLE, MOODLE_24_STABLE
    • Fixed Branches:
      MOODLE_22_STABLE, MOODLE_23_STABLE
    • Pull from Repository:
    • Pull Master Branch:
      MDL-33812-master

      Description

      backup_auto_keep has a default value of 1 (one), which I have not changed, yet there are currently SIX backups of each course in my backup_auto_destination directory.

      The value of backup_auto_keep also has no effect on the number of backups listed in the 'Automated Backups' section of the 'Restore' page for each course; only the most recent backup is ever listed at any one time.

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                3 Vote for this issue
                Watchers:
                8 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Fix Release Date:
                  10/Sep/12