开发者

MySQL backup in shared hosting on windows that does not allow remote connection

开发者 https://www.devze.com 2023-01-10 13:04 出处:网络
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).

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 !


I found a solution for this issue: http://www.phpmybackuppro.net/

it's a free tool that doesn't require a real installation. you upload the files, configure according to the instructions then can call the backup procedure on demand from a web page or manipulate it as you wish. great tool!


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.

0

精彩评论

暂无评论...
验证码 换一张
取 消