12

On Windows I can use NTFS drive compression to save heaps of disk space; usually 30%, often much more. It also improves read and write speeds at the cost of higher CPU usage; which isn’t an argument in my situation with CPU power to spare.

So on my Windows machines it’s always enabled. Is there a similar function on Ext4, or is there a different file system on (Ubuntu) Linux which supports compression? If so, how can I migrate my Ext4 file systems to that compressed file system?

1
14

There are two filesystems I'm familiar with that will give you compression on Linux: BTRFS and ZFS.

ZFS has a big following in the Sun/Solaris, FreeBSD, and FreeNAS communities. It works well on Linux, based on my experience with it. It doesn't come included in any of the big name distributions, but there are add-on repositories that make it very easy to install. See ZFS on Linux

BTRFS is newer and is Linux-only. I've been running it on Ubuntu 14.04 and found it stable. It supports multiple compression methods. I've found LZO compresses fairly well and is really fast; I don't see any performance slowdown from the compression operation.

1
  • 2020 update: ZFS now comes available with Ubuntu, and it is possible to apt install it on Debian and other systems from community repositories. – Ján Lalinský Mar 13 '20 at 0:28
1

Btrfs (B-tree file system) is your answer, it has parallels with Ext4, but offers a bigger change in features and design.

It is still relatively new, and majority of the production Linux installations are quite conservative, so you are probably going to have relatively limited community support.

Not the answer you're looking for? Browse other questions tagged or ask your own question.