Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
File:
CentOS 5.7 i386 20GB (gzipped -> 649MB)
use File::Copy;
copy($baseImageFileName, $imageFileName);
real 6m34.418s
user 0m0.394s
sys 0m47.059s
use IO::Uncompress::Gunzip qw(gunzip $GunzipError);
gunzip $baseImageFileName => $imageFileName or die "gunzip failed: $GunzipError\n";
real 8m6.076s
user 7m8.536s
sys 0m52.057s
system("zcat $baseImageFileName | cp --sparse=always /dev/stdin $imageFileName");
real 1m58.766s
user 1m51.205s
sys 0m12.642s
system("cp --sparse=always $baseImageFileName $imageFileName");
real 0m52.733s
user 0m1.832s
sys 0m21.427s
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.