Hi
The below code works very good, I created many backup of my very big mysql databases with this code.
But I have 2 datebases that have 50,000 tables. when i run the code, After 2 minutes i get result 0 without backup.
How i can change this code to fix the problem?
$username = "user_name";
$password = "password";
$hostname = "localhost";
$database = "db_name";
$username =escapeshellcmd($username);
$password =escapeshellcmd($password);
$hostname =escapeshellcmd($hostname);
$database =escapeshellcmd($database);
$backupFile='/home/myaccount/domains/mydomain.com/backup/'.date("Y-m-d-H-i-s").$database.'.sql';
$command = "mysqldump -u$username -p$password -h$hostname $database > $backupFile";
system($command, $result);
echo $result;