Mysql Dump Splitter / Benchmarks

Page content

Just a quick post to let you know some interesting finding on the sql splitter script i wrote:

The gzip compressed size

1.2G dump.sql.gz

The decompressed size

6.4G dump.sql

Time taken in seconds

splitter dump.sql  gzip -- 22
./splitter dump.sql.gz gzip -- 29
./splitter dump.sql   -- 43

The limiting factors looks to be the cpu with the gzip to gzip as php only runs on one core. Where as uncompressed to uncompressed was IO wait. I need to find if there is a way to run the gzopen used for reading and the gzopen used for writing on different cores.