Linux Today: Linux News On Internet Time.
Search Linux Today
Linux News Sections:  Developer -  High Performance -  Infrastructure -  IT Management -  Security -  Storage -
Linux Today Navigation
LT Home
Contribute
Contribute
Link to Us
Linux Jobs


Top White Papers

More on LinuxToday


SquashFS: Not Just for Embedded Systems

Jun 10, 2009, 22:32 (0 Talkback[s])
(Other stories by Jeffrey B. Layton)

"The original file was 3.2MB and after using gzip, with the "-9 option that provides maximum compression, the file is 268KB. Also notice the the extension ".gz" to indicate that the file has been compressed with gzip. The compression ratio, which is the ratio of the original size to the compressed size, is 11.9:1. The compression ratio is very dependent on the uncompressed data (how compressible is the data?) and the compression algorithm.

"There are generally two types of algorithms - lossless and lossy. Since this article is about data it will focus on lossless algorithms that have an encoding that be reversed to recreate the data exactly. There are a huge number of compression algorithms that take data and find a new encoding of the data that is much smaller. The difference between algorithms focuses on the techniques that create the new encoding. From the user perspective two of the biggest concerns are how much compression can be obtained and how much time and/or CPU usage it takes to perform the compression (or uncompression). However, the goal of all of them remains the same, to reduce the size of data to save space.

"The primary trade-offs in compressed file systems is that it takes CPU cycles and time to compress and uncompress data in return for reduced storage space. If you have the cycles and don't need a fast file system then you can save space. Alternatively, if you are severely memory or storage space constrained, then compressed file systems may be the only choice. This is most common in embedded systems that have severe storage restrictions."

Complete Story

Related Stories: