Download your favorite Linux distribution at LQ ISO.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 03-29-2004, 04:20 PM   #1
Registered: Nov 2003
Location: San Francisco, CA
Distribution: FreeBSD, OpenBSD, Gentoo, OS X
Posts: 80

Rep: Reputation: 15
mysqldump - backup *.*

| Database |
| discuss  |
| mysql    |
| test     |
I'd like to back up all three of those. As a matter of fact. I'd like to back them all up in such a a way that I can drop this dump right back into a mySQL server if this one shall ever fail. I have looked at the online docs and man and have decided that this seems to be what i want:

mysqldump -opt -Aa > mysqldump.sql
Is this sane or is there a better practiced method? the "A" means all databases and the "a" means Include all MySQL specific create options.
Old 03-29-2004, 04:42 PM   #2
Registered: Mar 2004
Location: Phila, PA
Distribution: SuSE 9.0 / RH 9 / Slackware 9.1
Posts: 110

Rep: Reputation: 15
Two ways of doing this:

1. Copy your whole data dir in /usr/lib (OR local)/mysql by hand or script (tarballing it or cp or mv or desktop mgr Copy / Paste)

2. or use mysqldump to export all DBs into INSERT SQL files (with data of course) like mysqldump --opt [DBname] > [/file/path/][fileName].sql

As for using dump for ALL DBs, I haven't tried it but hey, why not? I'd try it after tarballing the data dir JIC.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
mysqldump questions wh33t Programming 1 10-24-2005 08:07 PM
about mysqldump javier_ccs Programming 3 08-08-2005 06:13 PM
restore using mysqldump sporkit Linux - Networking 2 05-26-2004 05:34 PM
MySQLDump and Cron duerra Linux - Newbie 6 02-20-2004 08:18 AM
compressing mysqldump output linen0ise Linux - Newbie 0 07-28-2003 07:27 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 09:31 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration