Redis performance on FreeBSD vs Debian, help!

Hi, I'm trying to track down why I'm getting significantly better performance from Debian running Redis 2.6.7 (from the unstable repos) than my FreeBSD server. Both are running in VMWare on a Win7 box, one at a time, with no outside windows processes stealing CPU. Both installs are fresh (FreeBSD 9.1 and Debian 6) with only the base required software installed.

I'm starting Redis with the same options on both systems:
Code:
redis-server --unixsocket /tmp/redis.sock --unixsocketperm 755 --port 0

This starts a redis-server listening on a unix socket and disables TCP support. Higher is better for benchmark numbers. FWIW, I ran the same test with no VM on a retina macbook pro and saw similar performance to the FreeBSD screenshot.

FreeBSD:
RulRArX.png


Debian:
T27Q2ec.png


Any help/insight is greatly appreciated. Thanks!
 
Unless you actually install both on physical hardware, you really won't know which is more efficient. VMWare, Xen, VirtualBox, and others have a certain OS that is preferred followed by supported followed by experimental. Look at the hardware which is being simulated and adjust that.
The other problem which exists is that your host system is requiring a lot of resources. Take the same machine and install FreeBSD on it. You can then install Windows7 and Debian in virtual environments with the base system having low requirements.

I don't know what your situation is but maybe getting hold of some old hardware would help.
 
  • Thanks
Reactions: rck
Thanks for the reply @sossego.

I installed both platforms on real hardware and am seeing about 30% better performance on Debian vs FreeBSD. I recompiled Redis with both clang 3.2 and gcc 4.8 with only minor performance differences. I love that FreeBSD uses fewer resources on a fresh install, the ports system, and the portaudit utility but performance is important to my application. Are there any kernel parameters that I could tweak for additional performance? The machine will be a modern Xeon with 64GB of RAM.
 
Last edited by a moderator:
I could be related to the CPU scheduler. Have you tried DragonflyBSD? Its CPU scheduler is highly optimized for that kind of workload.
 
Back
Top