Dump it as SQL in a file and compress it. If it's a MySQL database it's easier and a lot faster to do a cold copy of the database files. Personally, I wouldn't trust an answer from a random guy. I would like to read it myself in the manual.
anjanesh: Pipe the output from tar, unzip, gunzip or bunzip2 to mysql. Ie. mysql < gunzip -c database_backup.sql.bz The -c argument is for: "-c --stdout --to-stdout Write output on standard output; keep original files unchanged." - gunzip's manpage.