By default, cPanel backups include all files and directories in your account. Over time, backups can become very large especially if they contain other backup archives (like WordPress backups). To save disk space and keep backups efficient, you can exclude specific files and directories.

 

Why Exclude Files?

  • Prevent backups from becoming unnecessarily large.

  • Avoid duplicating backup archives inside backups.

  • Reduce storage usage and speed up backup creation.

 

Steps to Exclude Files and Directories

  1. Log in to cPanel

  2. Create the Exclude File

    • In your home directory (/home/username/), create a file named:

      cpbackup-exclude.conf
      ​
  3. Add Exclusion Rules

    • Open the file in File Manager or a text editor.

    • Paste in the following example rules:

      *.jpa
      backup-*.tar.gz
      cpmove-*.tar.gz
      site-*.tar.gz
      */com_akeeba/backup/*
      */backupbuddy_backups/*
      public_html/cache/*
      tmp/*
      logs/*
      softaculous_backups/*
      */wp-content/uploads/wpcf7_captcha/*
      */wp-content/widget-cache/*
      */wp-content/cache/*
      */wptsc-cachedir/*
      */wp-content/ai1wm-backups
      
    • These cover common backup utilities (BackupBuddy, Akeeba), cache directories, and temporary files.

  4. Save the File

    • Save your changes to cpbackup-exclude.conf.

    • From now on, cPanel will skip these files and directories in backups.

Notes

  • You can add additional lines for any other files or directories you want excluded.

  • Be careful not to exclude critical site files or databases.

Hasznosnak találta ezt a választ? 0 A felhasználók hasznosnak találták ezt (0 Szavazat)

Powered by WHMCompleteSolution