Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
The "drush bb" command returns the message "Failed to compress the backup file. Try to perform a backup without compression."
Maybe the problem is in the OS settings. But I tried to do it on different machines, the result is the same.
Full error code:
$ drush bb [error]
WD backup_migrate: Could not compress backup file. Try backing up without compression. [error] [error]
WD backup_migrate: Could not complete the backup.
Comments
Comment #2
couturier CreditAttribution: couturier as a volunteer commentedPlease try upgrading to the 7.x-3.2 version released September 27, 2017, and see if this resolves your issue.
Comment #3
couturier CreditAttribution: couturier as a volunteer commentedClosing after more than two weeks with no activity.
Comment #4
Yuriy Mudriy CreditAttribution: Yuriy Mudriy as a volunteer and at DEWEB Studio for Drupal Ukraine Community commentedComment #5
Yuriy Mudriy CreditAttribution: Yuriy Mudriy as a volunteer and at DEWEB Studio for Drupal Ukraine Community commentedBug still exists in version: 7.x-3.5
May be related: https://www.drupal.org/project/backup_migrate/issues/1564408
Comment #6
couturier CreditAttribution: couturier as a volunteer commented@Yuriy Mudriy on comment #5, I'm not really sure if those issues are related. The one to which you linked is creating a double compression that is unreadable as a .gz file. This issue is more an error message stating that compression cannot occur in the first place. Do you know which of these two problems you might be having? Can you give us a copy of your error messages? Thanks.
Comment #7
DamienMcKennaIt'd be useful to add some hook_requirements / UI notes about which compression methods are available.
Comment #8
solideogloria CreditAttribution: solideogloria commentedI just experienced this error while testing an upgrade to PHP 7.2. Does zipping the file require a certain PHP extension?
Comment #9
solideogloria CreditAttribution: solideogloria commentedI had to install php-pecl-zip, which fixed the error.
Personally, I don't think this issue is related to the module at all, but rather to which PHP extensions are installed. I agree that adding hook_requirements would be useful, especially if backups are set to zip and the zip extension is not loaded. Maybe something like this, though you'd need to add some settings checks as well as check for gzip or other types:
Comment #10
joelpittetWe ran into this too, but we'd just installed zip extension but forgot to reload Apache/PHP-FPM so when the backup ran it was in a weird state where it tried to zip but failed.
Comment #11
solideogloria CreditAttribution: solideogloria commented