{"id":213,"date":"2021-07-23T12:25:15","date_gmt":"2021-07-23T12:25:15","guid":{"rendered":"https:\/\/ssdsunucum.com\/blog\/backup-retention-behavior\/"},"modified":"2021-07-23T12:25:15","modified_gmt":"2021-07-23T12:25:15","slug":"backup-retention-behavior","status":"publish","type":"post","link":"https:\/\/ssdsunucum.com\/blog\/backup-retention-behavior\/","title":{"rendered":"Backup Retention Behavior"},"content":{"rendered":"<\/p>\n<div class=\"col-md-9\">\n<div class=\"flex-column flex-md-row article-header\">\n<div id=\"versioned-article-header\">\n<p class=\"valid-version-info\"><em>Valid for versions 82 through the latest version<\/em><\/p>\n<\/div>\n<div id=\"version-select-group\" aria-label=\"select versions\">\n<h4>Version:<\/h4>\n<h4>82<\/h4>\n<\/div><\/div>\n<hr>\n<h2 id=\"overview\">Overview<\/h2>\n<p>This document explains the retention behavior of cPanel &#038; WHM\u2019s backup system. You can edit this behavior in WHM\u2019s <em>Backup Configuration<\/em> interface (<em>WHM &gt;&gt; Home &gt;&gt; Backup &gt;&gt; Backup Configuration<\/em>).<\/p>\n<h2 id=\"how-backup-retention-works\">How backup retention works<\/h2>\n<p>The system has two retention modes: the default backup retention behavior and strictly-enforced retention. Both behaviors ensure that the system saves the amount of successful backups that you set in WHM\u2019s <em>Backup Configuration<\/em> interface (<em>WHM &gt;&gt; Home &gt;&gt; Backup &gt;&gt; Backup Configuration<\/em>). However, the default backup retention behavior will retain that number of successful backups, along with failed backups, until the next successful backup completes. This means that the system could retain a number of backups larger than the amount that you set in WHM\u2019s <em>Backup Configuration<\/em> interface (<em>WHM &gt;&gt; Home &gt;&gt; Backup &gt;&gt; Backup Configuration<\/em>).<\/p>\n<p>When the strictly-enforced retention behavior encounters failed backups, it keeps at least one successful backup, but deletes any backups that surpass the retention limit that you set in WHM\u2019s <em>Backup Configuration<\/em> interface (<em>WHM &gt;&gt; Home &gt;&gt; Backup &gt;&gt; Backup Configuration<\/em>). Because the system will not surpass the retention limit, we recommend that you enable strictly-enforced retention if you have limited space on your server. To enable strictly-enforced retention, select the <em>Strictly enforce retention, regardless of backup success<\/em> setting in WHM\u2019s <em>Backup Configuration<\/em> interface (<em>WHM &gt;&gt; Home &gt;&gt; Backup &gt;&gt; Backup Configuration<\/em>).<\/p>\n<p>You can customize whether the system will notify you when a backup succeeds or fails. For more information on how to set up your backup notifications, read our Contact Manager documentation.<\/p>\n<h3 id=\"default-backup-retention-behavior\">Default backup retention behavior<\/h3>\n<p>When cPanel &#038; WHM completes a backup, the system deletes the oldest backup. When the system-generated backup fails, the system will keep the failed backup, it will <strong>not<\/strong> delete the oldest backup, and will continue to retain the oldest backups. This behavior ensures that the system keeps at least one successfully-completed backup.<\/p>\n<p>After the next backup successfully completes, the system will delete the oldest backups to return to the desired number of backups.<\/p>\n<h3 id=\"standard-backup-retention-behavior\">Standard backup retention behavior<\/h3>\n<p>If you run daily backups and retain four of them, the system will retain the latest four backup files:<\/p>\n<figure>\n    <img src=\"https:\/\/ssdsunucum.com\/blog\/wp-content\/uploads\/2021\/07\/backup-retention-examples-1-2-3-4.png\" width=\"300\" title=\"backup-retention-examples-1-2-3-4\"><br \/>\n<\/figure>\n<p>After the system successfully completes the next backup (5), it deletes the oldest backup (1):<\/p>\n<figure>\n    <img src=\"https:\/\/ssdsunucum.com\/blog\/wp-content\/uploads\/2021\/07\/backup-retention-examples-2-3-4-5.png\" width=\"300\" title=\"backup-retention-examples-2-3-4-5\"><br \/>\n<\/figure>\n<p>After the next backup fails (6F), the system does not delete the oldest backup (2):<\/p>\n<figure>\n    <img src=\"https:\/\/ssdsunucum.com\/blog\/wp-content\/uploads\/2021\/07\/backup-retention-examples-2-3-4-5-6f.png\" width=\"375\" title=\"backup-retention-examples-2-3-4-5-6f\"><br \/>\n<\/figure>\n<p>If several more backups fail (7F, 8F, and 9F), the system will continue to retain the oldest backups:<\/p>\n<figure>\n    <img src=\"https:\/\/ssdsunucum.com\/blog\/wp-content\/uploads\/2021\/07\/backup-retention-examples-2-3-4-5-6f-7f-8f-9f.png\" width=\"600\" title=\"backup-retention-examples-2-3-4-5-6f-7f-8f-9f\"><br \/>\n<\/figure>\n<p>After the next complete backup succeeds (10), the system deletes the oldest backups so that it only retains four backups:<\/p>\n<figure>\n    <img src=\"https:\/\/ssdsunucum.com\/blog\/wp-content\/uploads\/2021\/07\/backup-retention-examples-7f-8f-9f-10.png\" width=\"300\" title=\"backup-retention-examples-7f-8f-9f-10\"><br \/>\n<\/figure>\n<h3 id=\"backup-retention-behavior-with-the-strictly-enforce-retention-setting\">Backup retention behavior with the Strictly enforce retention setting<\/h3>\n<p>With strictly-enforced retention, cPanel &#038; WHM will delete the oldest backup when the system completes a backup. However, when the system-generated backup fails, the system will keep the failed backup and delete the oldest backup. Also, it will <strong>not<\/strong> continue to retain the oldest backup, except for the last successful backup. This behavior ensures that the system keeps at least one successful backup.<\/p>\n<p>After the next backup succeeds, the system will delete the oldest backups to return to the desired number of backups.<\/p>\n<p>If you run daily backups and retain four of them, the system will retain the latest four backup files:<\/p>\n<figure>\n    <img src=\"https:\/\/ssdsunucum.com\/blog\/wp-content\/uploads\/2021\/07\/backup-retention-examples-1-2-3-4.png\" width=\"300\" title=\"backup-retention-examples-1-2-3-4\"><br \/>\n<\/figure>\n<p>After the system successfully completes the next backup (5), it deletes the oldest backup (1):<\/p>\n<figure>\n    <img src=\"https:\/\/ssdsunucum.com\/blog\/wp-content\/uploads\/2021\/07\/backup-retention-examples-2-3-4-5.png\" width=\"300\" title=\"backup-retention-examples-2-3-4-5\"><br \/>\n<\/figure>\n<p>After the system generates a partial backup (6F), it deletes the oldest backup:<\/p>\n<figure>\n    <img src=\"https:\/\/ssdsunucum.com\/blog\/wp-content\/uploads\/2021\/07\/backup-retention-examples-2-3-4-5-6f.png\" width=\"375\" title=\"backup-retention-examples-2-3-4-5-6f\"><br \/>\n<\/figure>\n<p>After several more partial backups (7F and 8F), the system only retains partial backups:<\/p>\n<figure>\n    <img src=\"https:\/\/ssdsunucum.com\/blog\/wp-content\/uploads\/2021\/07\/backup-retention-examples-4-5-6f-7f.png\" width=\"300\" title=\"backup-retention-examples-4-5-6f-7f\"><br \/>\n<\/figure>\n<p>After the next partial backup (9F), the system must retain the last successful backup (5), so it deletes the oldest partial backup in order to retain only four backup files:<\/p>\n<figure>\n    <img src=\"https:\/\/ssdsunucum.com\/blog\/wp-content\/uploads\/2021\/07\/backup-retention-examples-5-7f-8f-9f.png\" width=\"300\" title=\"backup-retention-examples-5-7f-8f-9f\"><br \/>\n<\/figure>\n<p>After the next complete backup completes (10), the system can delete the oldest backup (5) so that it only retains four backups, with at least one successful backup.<\/p>\n<figure>\n    <img src=\"https:\/\/ssdsunucum.com\/blog\/wp-content\/uploads\/2021\/07\/backup-retention-examples-7f-8f-9f-10.png\" width=\"300\" title=\"backup-retention-examples-7f-8f-9f-10\"><br \/>\n<\/figure>\n<\/p><\/div>\n","protected":false},"excerpt":{"rendered":"<p>Valid for versions 82 through the latest version Version: 82 Overview This document explains the retention behavior of cPanel &#038; WHM\u2019s backup system. You can edit this behavior in WHM\u2019s Backup Configuration interface (WHM &gt;&gt; Home &gt;&gt; Backup &gt;&gt; Backup Configuration). How backup retention works The system has two retention modes: the default backup retention &hellip;<\/p>\n","protected":false},"author":1,"featured_media":214,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[1],"tags":[],"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/ssdsunucum.com\/blog\/wp-json\/wp\/v2\/posts\/213"}],"collection":[{"href":"https:\/\/ssdsunucum.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/ssdsunucum.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/ssdsunucum.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/ssdsunucum.com\/blog\/wp-json\/wp\/v2\/comments?post=213"}],"version-history":[{"count":0,"href":"https:\/\/ssdsunucum.com\/blog\/wp-json\/wp\/v2\/posts\/213\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/ssdsunucum.com\/blog\/wp-json\/wp\/v2\/media\/214"}],"wp:attachment":[{"href":"https:\/\/ssdsunucum.com\/blog\/wp-json\/wp\/v2\/media?parent=213"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/ssdsunucum.com\/blog\/wp-json\/wp\/v2\/categories?post=213"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/ssdsunucum.com\/blog\/wp-json\/wp\/v2\/tags?post=213"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}