views:

28

answers:

1

Hi all, after googling for a long time, I decided to ask this:

I've uploaded a site to a shared hosting that does not allow remote DB connection due to security issues (according to them). the Data is very important to me and I'd like to back it up automatically on a daily basis (in addition to the hosts daily backup).

I'm writing the code in ASP.NET and using MySQL DB. The server is Win 2003 and using PHPmyAdmin. as mentioned in the headline - I cannot connect to it remotely.

how can I schedule an automatic backup for the DB? Thanks you very much !

+1  A: 

Depending on your host, you may be able to run crons (scheduled tasks in windows) on the box. If that's the case, and if you have access to mysqldump, then you could mysqldump the contents of the database using a command such as ...

mysqldump -u database_username -pdatabase_password -h 127.0.0.1 > ~/database.backup.sql

Granted, that's a more unix solution than what you might need. I think the hangup you're experiencing, is that you're thinking this has anything do do with your code. It doesn't.

I presume you have some sort of web control panel on this host? If so, look up the cron, or scheduled tasks feature on it (very likely to be there), and see what your options are from there.

Cory Collier
the control panel is parallels but has no way of scheduling tasks.. (I wish)... what can I do except asking him to run this for me?
Guy