[olug] Filesystem Compression

Nick Walter nwalter at neb.rr.com
Fri Oct 29 15:25:35 UTC 2004


I'm not aware of any mature products to do on-the-fly compression at the
filesystem level for linux.  

What I typically do for backups is compressed tarfiles or simply
individually compress the backed up files (with gzip).  A lot depends on
how immediately accessible you need the backup data to be and how fast
you need the backup to finish.

For archival purposes, you could do the backup uncompressed and then
compress it later once all the data is backed up.  Keeping backups of a
filesystem quick reduces the headaches associated with an inconsistent
snapshot.

If there is no disk space available to do the backup uncompressed it is
quite possible to copy a file and gzip it at the same time to achieve
on-the-fly backup and compression in one step.  Here a quick and dirty
little shell script illustrating how it might be done:

for X in `ls /mydirectory/importantfiles/*`
do
  Y=basename $X
  gzip -c $X|dd of=/mybackup/directory/$Y
done

Nick Walter

On Fri, 2004-10-29 at 09:46, Andrew Embury wrote:
> Is it possible to do compression on any of the major, stable Linux file
> systems?  I'm working on a multi-terabyte disk-to-disk backup system and
> would like to have on-the-fly compression enabled at the filesystem level.
> The best I could find was an unsupported patch for ext2 that never seemed
> to be integrated into the kernel.
> 
> I'm running RedHat EL ES 3.  Stability is the #1 concern.
> 
> Thanks,
> 
> Drew
> _______________________________________________
> OLUG mailing list
> OLUG at olug.org
> http://lists.olug.org/mailman/listinfo/olug





More information about the OLUG mailing list