Skip to Content
High Performance MySQL, 3rd Edition
book

High Performance MySQL, 3rd Edition

by Baron Schwartz, Peter Zaitsev, Vadim Tkachenko
March 2012
Intermediate to advanced
823 pages
29h 40m
English
O'Reilly Media, Inc.
Content preview from High Performance MySQL, 3rd Edition

Appendix C. Transferring Large Files

Copying, compressing, and decompressing huge files (often across a network) are common tasks when administering MySQL, initializing servers, cloning replicas, and performing backups and recovery operations. The fastest and best ways to do these jobs are not always the most obvious, and the difference between good and bad methods can be significant. This appendix shows some examples of how to copy a large backup image from one server to another using common Unix utilities.

It’s common to begin with an uncompressed file, such as one server’s InnoDB tablespace and log files. You also want the file to be decompressed when you finish copying it to the destination, of course. The other common scenario is to begin with a compressed file, such as a backup image, and finish with a decompressed file.

If you have limited network capacity, it’s usually a good idea to send the files across the network in compressed form. You might also need to do a secure transfer, so your data isn’t compromised; this is a common requirement for backup images.

Copying Files

The task, then, is to do the following efficiently:

  1. (Optionally) compress the data.

  2. Send it to another machine.

  3. Decompress the data into its final destination.

  4. Verify the files aren’t corrupted after copying.

We’ve benchmarked various methods of achieving these goals. The rest of this appendix shows you how we did it and what we found to be the fastest way.

For many of the purposes we’ve discussed in this book, ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

High Performance MySQL, 2nd Edition

High Performance MySQL, 2nd Edition

Jeremy D. Zawodny, Derek J. Balling, Baron Schwartz, Peter Zaitsev, Arjen Lentz, Vadim Tkachenko
High Performance MySQL

High Performance MySQL

Jeremy D. Zawodny, Derek J. Balling
High Performance MySQL, 4th Edition

High Performance MySQL, 4th Edition

Silvia Botros, Jeremy Tinley

Publisher Resources

ISBN: 9781449332471Errata PageSupplemental Content