KitzKikz  KitzKikz: FileCompressionTest   RecentChanges 
 PopularPages 
 SearchPages 
 Home | Trail - FileCompressionTest
 
 

For my own twisted interest, I ran a few unix file compression methods on 25,000 concatenated copies of the Declaration of Independence (html version, 13,641 bytes).

MethodBytesTimeRatio
Uncompressed:341,025,000-0.000%
compress:90,666,2813m 39.374s73.414%
bzip2:4,859,9211h 45m 55.446s98.575%
zip:2,378,3801m 51.983s99.303%
gzip:2,378,3131m 43.769s99.303%
gzip -9:2,319,2641m 42.842s99.320%

Looks like gzip is the winner.


How to create a file containing 25,000 copies of the Declaration of Independence

Brute Force Method:

    curl http://earlyamerica.com/earlyamerica/freedom/doi/text.html > f
    cat f f f f f f f f f f > fd
    cat fd fd fd fd fd fd fd fd fd fd > fh
    cat fh fh fh fh fh fh fh fh fh fh > fk
    cat fk fk fk fk fk fk fk fk fk fk > f10k
    cat f10k f10k fk fk fk fk fk > doi25k
    rm f fd fh fk f10k

Perl Method:

    perl -e 'print `curl http://earlyamerica.com/earlyamerica/freedom/doi/text.html` x 25000' > doi25k


Let freedom ring!

 

   

 
 EditThisPage · LinksToPage · PageInfo 12/07/05 01:56:54  ·  0.0408s