tbrehm
2013-08-09 6ec95189e4d029ee5f8fb288ffe9906956614fce
Fixed: FS#3053 - Empty sql backups
1 files modified
6 ■■■■ changed files
server/cron_daily.php 6 ●●●● patch | view | raw | blame | history
server/cron_daily.php
@@ -1231,7 +1231,8 @@
                $db_id = $rec['database_id'];
                $db_name = $rec['database_name'];
                $db_backup_file = 'db_'.$db_name.'_'.date('Y-m-d_H-i').'.sql';
                $command = "mysqldump -h '".escapeshellcmd($clientdb_host)."' -u '".escapeshellcmd($clientdb_user)."' -p'".escapeshellcmd($clientdb_password)."' -c --add-drop-table --create-options --quick --result-file='".$db_backup_dir.'/'.$db_backup_file."' '".$db_name."'";
                //$command = "mysqldump -h '".escapeshellcmd($clientdb_host)."' -u '".escapeshellcmd($clientdb_user)."' -p'".escapeshellcmd($clientdb_password)."' -c --add-drop-table --create-options --quick --result-file='".$db_backup_dir.'/'.$db_backup_file."' '".$db_name."'";
                $command = "mysqldump -h ".escapeshellarg($clientdb_host)." -u ".escapeshellarg($clientdb_user)." -p".escapeshellarg($clientdb_password)." -c --add-drop-table --create-options --quick --result-file='".$db_backup_dir.'/'.$db_backup_file."' '".$db_name."'";
                exec($command, $tmp_output, $retval);
                //* Compress the backup with gzip
@@ -1285,8 +1286,7 @@
                }
                unset($files);
                unset($dir_handle);
            }
                unset($dir_handle            }
        }
        unset($clientdb_host);