On 8/27/05, Carstea Catalin <[EMAIL PROTECTED]> wrote: > how to backup and restore mysql databases?
http://dev.mysql.com/doc/mysql/en/mysqldump.html most relevent part of it ( you will need to do -u$username -p$password to login: - - snip - - The most common use of mysqldump is probably for making a backup of an entire database: shell> mysqldump --opt db_name > backup-file.sql You can read the dump file back into the server like this: shell> mysql db_name < backup-file.sql Or like this: shell> mysql -e "source /path-to-backup/backup-file.sql" db_name mysqldump is also very useful for populating databases by copying data from one MySQL server to another: shell> mysqldump --opt db_name | mysql --host=remote_host -C db_name It is possible to dump several databases with one command: shell> mysqldump --databases db_name1 [db_name2 ...] > my_databases.sql If you want to dump all databases, use the --all-databases option: shell> mysqldump --all-databases > all_databases.sql - - snip - - > > -- > Any help would be greatly appreciated. > regards, > Carstea Catalin > _______________________________________________ > freebsd-questions@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-questions > To unsubscribe, send any mail to "[EMAIL PROTECTED]" > _______________________________________________ freebsd-questions@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]"