Friday, May 10, 2013

Using Btrfs not for the faint of heart

Btrfs is stable enough that many Linux distributions are including it as an optional filesystem. This, of course, includes Ubuntu. Add in the fact that there's enterprise support available for this new filesystem since February 2012 and you can guess that a lot of people are going to think everything's fine with this filesystem.

While you can indeed use btrfs on your computer, it's still very much not recommended unless you know what to do when things go awry. You'll also need to be aware that using btrfs for / may actually be bad for your computer performance-wise.

I've tried a btrfs multi-device setup for / on my PC and it's a rather interesting experience. I've simply added a second hard disk to the filesystem making use of the defaults (which should be sane). Having the combined bandwidth of 2 hard disks running together certainly can breathe new life to an old pair of hard disks. Life would probably be simpler if I had simply bought a new hard disk, though.

With 50MB/s transfer rates each, my combined dual 160GB setup just about matches my very much newer 2TB drive's transfer speeds. I didn't do any systematic tests. This is a rather subjective opinion of mine based on personal observation so take it with a big pinch of salt.

Well, anyway, aside from the slow boot times that btrfs seem to provide (on Ubuntu, at least) there's also the occasional system freeze. I'm tentatively placing the blame on btrfs since there doesn't appear to be anything else wrong with the system hardware or software. And what a disaster it is when Ubuntu can no longer recovery after numerous crashes over time.

Want a stable system? Stick to ext3/4 for now. Even now I'm picking up the pieces from the most recent crash. / can no longer be mounted. Not even from a LiveCD environment. Good thing I have a separated storage drive using ext4 so it's not a complete loss just a very very annoying one.