|
|
|||||||||
|
|||||||||
|
|||||||||
| |
|||
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Display Modes |
|
|
|
Stay one step ahead of the competition. Evaluate and give feedback
on some of the hottest web development tools on the market today.
Make your opinion heard! Click
Here
|
|
#1
|
|||
|
|||
|
MySQL Backup
I have a small MySQL database (25 M) on a shared Linux box hosted by a service provider.
I want to schedule a backup of this database on my Windows machine on a daily basis (example: everyday at 2 AM) Are there any free scripts or low priced commercial software ($20-$50 for single user) to do this. Please suggest me. Thank You |
|
#2
|
||||
|
||||
|
Just write a script on the server that invokes mysqldump and redirects to a file. Then have your Windows box FTP in and grab the file every night. If you don't have cron access on the Linux box, write a PHPscript that your Windows box can access every night at 2 AM that runs the mysqldump command, and then, a little while later, have your Windows box FTP in to get the file.
|
|
#3
|
|||
|
|||
|
Hi dhouston
Thanks for taking time to reply me. Indeed, My Service provider doesn't allow to use commandline stuffs like following: >mysqldump -C -h HOST -uUSER -pPASSWD Database[table] > c:\localpath If I could execute the above command the problem would have solved :-) Thank You very much for your kind respond. |
|
#4
|
||||
|
||||
|
Yikes, that stinks. It shouldn't be too hard, though, to use some of PHP's built-in functions to emulate what mysqldump does. For example, you could use the mysql_list_fields(), mysql_list_dbs(), and mysql_list_tables() functions to reconstruct the table creation statement, or at least to print some clues as to what the structure looks like. Then you could just select all rows from all tables and write out a bunch of insert statements (or just a CSV or tab-delimited file). Send all this to a text file and have your Windows box run a scheduled task to download.
|
![]() |
| Viewing: Dev Articles Community Forums > Databases > MySQL Development > MySQL Backup |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|