My OS is Ubuntu 10.10. I have several small sites (all on various shared hosts) and I'm thinking that it'd be probably good idea to regularly backup mysql databases from these remote shared hosts. I currently do it manually and it seem to be while not laborious but definitely boring process (phpmyadmin).

How should I go about it (no ssh access available)?

If do it like this:

mysqldump -u root -p[root_password] [database_name] -h mysql_host > dumpfilename.sql

Does that mean that password is being transferred in plain text?

  • If you are executing mysqldump with -p option from a commandline, then you are making the password visible in the process commandline, which can be viewed by anyone executing the ps command. Commented Nov 30, 2011 at 19:01

3 Answers 3


Specifying the password that way is just insecure on your machine. Over the network it's just the same way that MySQL clients connect to your database. As far as I read, the username and password are hashed, so you are not sending your password in plain text.

In your situation I would write a simple wrapper script, something like

for host in host1 host2 host3
    do mysqldump ...

Check out


Also consider the incremental backups


Check out maatkit, which automates most of the stuff.

  • I would suggest make the mysql backups locally on that machine and periodically sync them to the internal or main site for compressed backups. Just make sure the dumps are stored in a relatively secured directory with restrictive permissions. It would make things easy as well when you are about to restore the databases on a remote site when needed. Commented Nov 30, 2011 at 19:04

backup-manager is the most complete and powerful in my opinion.

  • What others have you considered? Why do you think this is the best? OPs parameters might be quite different than yours...
    – vonbrand
    Commented Mar 21, 2013 at 20:59
  • It can compress file, automatic and scheduled backup, deleting old saves, splitting backups into smaller part. It ave also incremental feature, launch command before/after backup, FTP/SVN/... sync, burning on CD/DVD, multiple SQL database dump, etc. And all configurations is simple (one file) and well documented.You just pick what feature you want to use.
    – GHugo
    Commented Mar 21, 2013 at 21:23

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .