Backing up mysql database


i am trying to backup mysql database using commandline linux. i am following this

mysqldump --opt -uusername -ppassword -h yourMySQLHostname dbname > output.sql

but i dont see any output.sql when i login to ftp. i have enabled ssh in dreamhost panel. plse help me.


It’s a lot easier to just do it through the panel using phpadmin at this link.

It’ll even download it directly to your machine.

Note: If you are actually successfully using the command line you won’t have to FTP in to see the file. It’ll be right in the same directory from which you executed the command.

Note Also: DH mysql servers are not hosted at “localhost” like most documentation shows. There’s not enough info in your post to make any determination as to whether you got that information correct or not.

Trust me - phpadmin is a pretty slick way to do what you’re trying to do unless you want to do it as a cron job - and since you’ve discussed mixing ssh and ftp, I’m going to guess that you’re not working with cron yet.

Wholly - Use promo code WhollyMindless for full 97$ credit. Let me know if you want something else!


Here’s my format:
/usr/bin/mysqldump --all-databases -hDBMACHINE.MYDOMAIN.COM -uUSERNAME -pPASSWORD > ~/DB.sql

Keep the -u and -p and change the uppercase stuff.
The ~/ means to dump the db into my home directory, and not my domain directory or some other odd place.



[quote]Here’s my format:
/usr/bin/mysqldump --all-databases -hDBMACHINE.MYDOMAIN.COM -uUSERNAME -pPASSWORD > ~/DB.sql[/quote]
It works for me nicely. Have you do nslookup to your DBMACHINE.MYDOMAIN.COM ?

Or … I don’t know if it is the problem. See the allowable host value from your panel => If you access from DH’s server that value will be set to but if you access it from local you should set to your IP address.

Hope it helps.


Need promo code? Use [color=#00CC00]Supernova[/color] (you get $97 off on yearly plans): SIGN UP NOW !

Check out instructions on how to apply the code !