Compression Tutorials

Exclude files from Tar Archive

Tar is a UNIX/Linux utility which is used to compress files for storage in an archive. When we tell tar to compress and create an archive of a directory, it will go ahead and include all the files in that directory.

Sometimes we may want to exclude a particular file from an archive. Tar allows use a convenient option to specify a file or files to exclude when making the archive. The tutorial below shows how we do a tar exclude file operation by using the command line.

Enable Compression on Apache with mod_deflate

Enabling compression on Apache is a trade-off between CPU load and bandwidth. It is usually faster to compress content as more time is saved when transferring a smaller file as opposed to the minimum CPU time which is required to compress the data in the first place. We first need to enable mod_deflate. This is the module which handles the compression of the data.

On modern Linux versions with Apache 2:

a2enmod deflate

On Windows edit the "httpd.conf" file and uncomment the following line like so: