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

Prevent mdl_backup_log from growing endlessly

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Minor
    • Resolution: Duplicate
    • Affects Version/s: 1.9.13, 2.1.1, 2.2.5, 2.3, Future Dev
    • Fix Version/s: None
    • Component/s: Backup
    • Labels:
    • Affected Branches:
      MOODLE_19_STABLE, MOODLE_21_STABLE, MOODLE_22_STABLE, MOODLE_23_STABLE

      Description

      As time progresses, mdl_backup_log grows and grows... unless i EMPTY it by using SQL : TRUNCATE TABLE `mdl_backup_log`

      If all backups goes well, It seems to use unnecessary RAM or Disk space.

      How about adding a log purging function to the cron.php script that removes older then one month log entries?
      The "keep dates range" can be adjusted from the admin menu.

      KeepDatesRange = 30; (days)
      DELETE * FROM `mdl_backup_log` WHERE from_unixtime(time) > DATE_SUB(now(),INTERVAL KeepDatesRange DAY)

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: