Link to home
Create AccountLog in
Avatar of ncw
ncw

asked on

Php script to copy MySql database from one server to another via a remote connection

Is there a free Php script available that will copy a MySql database from a remote server to a host server via a remote connection? I can't do this using mysqldump because I don't have SSH access on the remote server. At the moment I'm having to download the Db via PhpMyadmin and upload on the new server via PhpMyadmin.
Avatar of Ray Paseur
Ray Paseur
Flag of United States of America image

How often do you want to do this?
Avatar of gr8gonzo
If you have remote MySQL access on your remote server and SSH access on the new server, then you can simply run mysqldump from the new server and give it credentials to the old/remote server.

If you just need to do this on occasion with small databases, then I recommend you use HeidiSQL. It's a free MySQL GUI tool for Windows, and it has a feature that allows you to copy databases between servers (although the tool itself is labeled as "Export database to SQL" and you have to choose the new database as the destination in the popup). It's far superior to phpMyAdmin, in my opinion.
Avatar of ncw
ncw

ASKER

As the title suggests, I'm looking for a Php script.

> How often do you want to do this?
May be once a month.
Avatar of ncw

ASKER

I've requested that this question be deleted for the following reason:

No solution found.
ASKER CERTIFIED SOLUTION
Avatar of gr8gonzo
gr8gonzo
Flag of United States of America image

Link to home
membership
Create an account to see this answer
Signing up is free. No credit card required.
Create Account