You can compress files with the vxcompress command. The vxcompress command performs the following functions:
See the vxcompress
(1) manual page.
You can specify one or more filenames. If you specify the -r option, then you can specify directories, and the vxcompress command operates recursively on the directories.
You can specify the file compression algorithm and strength with the vxcompress -t command. The default algorithm is gzip, which is currently the only supported algorithm. The strength is a number from 1 to 9, with a default of 6. Strength 1 gives the fastest performance with least compression, while strength 9 gives the slowest performance with the greatest compression. For example, you specify strength 3 gzip compression as "gzip-3".
When reporting the compression details for a file, the vxcompress -l command or vxcompress -L command displays the following information:
Compression algorithm
Strength
Compression block size
% of file data saved by compression
% of extents that are compressed
This is the percentage of extents in the file that are compressed, without regard to the size of the extents. This percentage provides an idea of whether it is worthwhile to recompress the file. After recompression, the percentage is always 100%. However, shared extents are counted as uncompressed, and thus the percentage will be less than 100% if the file has shared extents.
If you attempt to compress a file with the vxcompress command and the extents have data that cannot be compressed, the command still marks the file as compressed and replaces the extents with compressed extent descriptors.
If you recompress a file, you do not need to specify any options with the vxcompress command. The command automatically uses the options that you used to compress the file previously.