Does ZFS cache Compressed or Uncompressed data in a ZFS file-system with compression turned on?
- by George Bailey
ZFS supports file-system compression and it also caches frequently or recently accessed data.
If a system has lots of CPU but the underlying data storage system is slow. It is possible that ZFS would perform better with compression turned on. This can be easily tested when writing files by measuring CPU and disk usage and throughput. (of course latency may exist,, but this would not be an issue for large files).
But what about cache? If data will have to be decompressed every time it is read then this is probably less of a good idea.
Is the cached data compressed?. Does anybody have some information on this?