2

I have a Magento 1.7.0.2 installation on a website and want to backup in the cloud using Codeguard (codeguard.com) through FTP. I have been asked which directories to pick for backup and suggested to remove /var/cache and /var/temp directories because codeguard compares different versions of backups and updates subsequent backups accordingly. Obviously, cache and temp folders shouldn't be backed up.

My question concerns which other directories and files should I not back up? My /var directory consists of the following sub-directories and files: cache, export, locks, package, session, tmp and the .htaccess file.

user1762704
  • 49
  • 1
  • 5

1 Answers1

7

You don't need to backup:

  • /media/catalog/product/cache
  • /var/cache
  • /var/session
  • /var/tmp

You may backup:

  • /var/export, if you use scheduled import/export and need results of import export to be saved. However, these are not very important.
  • /var/locks, if you backup DB snapshot together with the sources, as there are locks for some ongoing processes are kept
  • /var/log, if you're interested in keeping logs, exceptions
  • /var/package, if you use Magento Connect to install extensions (but do not backup /var/package/tmp)

You need to backup:

  • /var/.htaccess

I also advice you to make a snapshot of your Magento store at one day and compare with a snapshot made a week later. That is because your customization or 3rd party extensions may add more folders/files, that should be excluded. So the list of added/changed files will help you to see, what else should not be stored in a backup.

Andrey Tserkus
  • 3,644
  • 17
  • 24