Jump to content

Super easy and fast way to backup your DB

Recommended Posts

I created a tiny PHP script which I intended to run through shell to backup my DB. What impressed me is that the script works fine running it from a browser as well. So by using it, at any time, I have within seconds a dump of my DB.


$command = "mysqldump -u<db_username> -p<db_password> <db_name> | gzip > backupDB_" . date( "H:i:s_d-m-Y" ) . ".sql.gz";

system( $command );



Link to comment
Share on other sites


This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Create New...