Backup and Migrate gives me a tar ball I have a local site and a development site. I want to replace my development site with my local site. I used the Backup and Migrate module to backup the development site into a .gz file. All good. But when I did the same again with the local environment, it came back as a .tar file, no matter which compression option I chose.

When I tried to restore onto the development site using the local site's tarball, it specified it needs a .gz or .zip file. So I ran:


  tar -cvzf 127.0.1.1-2015-01-12T17-23-50.sitearchive.tar.gz
  127.0.1.1-2015-01-12T17-23-50.sitearchive.tar


This time, it came back with this error:


  Unable to restore from file
  /tmp/backup_migrate_vbDBRs.0.1.1-2015-01-12t17-23-50.sitearchive.tar
  because a tar file can't be restored to this database.


How can I correctly restore a backup from my local site onto the development site. Or is this method completely wrong and I should be doing something else, like creating a new site from scratch and restoring that?
This is not an issue with the module.

The most likely cause of the problem is that your local system is missing gzip, so the backup and migrate module is unable to turn the tar-file into a gzipped tar file.

The command to do that is not tar -cvzf (which you've tried), but gzip. I.e.:

gzip 127.0.1.1-2015-01-12T17-23-50.sitearchive.tar


This should produce a valid 127.0.1.1-2015-01-12T17-23-50.sitearchive.tar.gz, but if you try this on the local system, it will probably fail telling you that it can't locate gzip.

The best fix would be to install gzip on the local system.

Alternatively, you may export the file to some system that has gzip, and do the gizipping there.