Issue
During commands such as drush sql-sync, blt sync, or blt sync:refresh, the command errors out with output similar to:
sh: 1: cannot create auto.gz: Permission denied
[error] Database dump failed [3.1 sec, 8 MB]
Or:
Output is empty.
Resolution
This is most likely an issue of Drush version mismatches between environments. If you are running Drush 9 locally but Drush 8 in your remote environment, you will encounter this issue.
It has been documented by the Drush team.
Option 1: Deploy Drush 9 to the remote environment.
Option 2: Temporarily add a --source-dump
option per the Drush docs during the sql-sync command.