FreeBSD ZFS compression

Joined
Nov 18, 2005
Messages
663
A few weeks ago, I was evaluating ZFS on FreeBSD 8.0 on ESXi 4. After working with it for a bit, I managed to get it running acceptably as an iSCSI target. When I turned on ZFS compression, performance took a major hit and worse, the entire VM would pause for several seconds.

My problem is essentially identical to this thread:
http://lists.freebsd.org/pipermail/freebsd-fs/2009-December/007343.html

In the case of the above thread, the author is also running FreeBSD on ESXi probably in a single CPU configuration.

Has anyone tried ZFS compression on a reasonably powerful hardware box - dual core or better? How was the performance?

I'd try, but I lost my spare hardware box... a Core 2 Duo doesn't get to sit around undeployed for too long. :(
 
I tried to do this on my quadcore box, but i couldn't slow down my system. I even used "zfs set compression=gzip-9" - the highest level of compression ZFS supports. Still didn't got any major slowdowns of any kind.

FreeBSD may not like being run in a VM, and i've seen the hz=100 is a 'requirement' for FreeBSD to be running in a VM. You may want to test this out, by putting the following in /boot/loader.conf:
kern.hz="100"

Also, can you post a screenshot of your top -S output during the compression?
Is there any way you can test without virtualization?
 
Just did a test on gzip-9 compression; got 244MB/s. It also doesn't seem to be hanging or not being responsive, as i'm doing this directly on the console; and would notice any blocking/hanging/skipping behavior.
 
Thanks for testing. I'll try the 100hz suggestion and see what happens. Fortunately, its not really important that I get it running in a VM properly as my filer box is going to be a Xeon x3430 running directly on the hardware. I wish I still had my Core 2 Duo for testing, but unfortunately, I don't have any other spare hardware platforms that are worth anything. [email protected] anyone? lol

I am trying to decide between FreeBSD and Solaris and your information has helped greatly.
 
Well i would very much like to know if this behavior you described is the result of FreeBSD being virtualized or something else. If you could test with dedicated FreeBSD without VM/hypervisor, that would be great. Do know that ZFS and FreeBSD is highly threaded; the compression test would cause all your cores to be used to full extent.

OpenSolaris may behave better under virtualization, as that's a key area Sun invested on and thus a big priority.
 
I tried the 100hz suggesting and it worked. No pauses. Performance was fairly close to that of Solaris. Solaris still had an edge because the COMSTAR iscsi target uses ZFS caching whereas istgt does not. For some reason, top was showing minimal CPU load during the compression test. Atto from Windows showed 40-50mb/sec on the compressed LUN. Not bad at all.

You'd think that OpenSolaris would play nice with virtualization. 2009.06 core dumps on ESXi. Solaris 10u8 works fine though. OpenSolaris also doesn't give you updates between releases unless you are willing to use /dev. I'm not, so its between Solaris and FreeBSD.

I should have my hardware build done by Thursday evening. I'm feeling pretty good about FreeBSD so I'll try loading it first and see what happens. Worst case, I'll have to load Solaris. Hopefully, I'll have some news on Friday or Saturday.

How is Samba performance on FreeBSD?
 
Back
Top