Hi, I'm building a test asterisk server and building the latest kernel I got to wonder if there are any specific recommendations about schedulers and so forth for optimum performance. There are a few areas that raise questions in my mind and I wonder if anyone has any opinions/comments on which settings are most suitable for use with asterisk: SLAB Allocator (SLAB or SLUB?) Tickless System (?) Preemption model (?) IO Scheduler (Anticipatory, Deadline or CFQ?) Flat or Sparse Memory (?) Timer Frequency (100Hz .. 1000hz) Cheers Alan -- The way out is open! http://www.theopensourcerer.com
Alan Lord wrote:> I'm building a test asterisk server and building the latest kernel I got > to wonder if there are any specific recommendations about schedulers and > so forth for optimum performance. > > There are a few areas that raise questions in my mind and I wonder if > anyone has any opinions/comments on which settings are most suitable for > use with asterisk: > > SLAB Allocator (SLAB or SLUB?) > Tickless System (?) > Preemption model (?) > IO Scheduler (Anticipatory, Deadline or CFQ?) > Flat or Sparse Memory (?) > Timer Frequency (100Hz .. 1000hz) >Alan, Good post! I've wondered about the preemption model and I/O scheduler myself, so I'll be keeping an eye on this thread. As the Linux kernel evolves to allow configuration as a fully deterministic real-time OS, it will be interesting to see what settings provide the optimal environment for Asterisk. As for my contribution to the thread, I have a few tips for configuring the kernel if you plan on using ztdummy for timing: 1. The kernel version must be at least 2.6.13 2. The kernel must be configured with a timer frequency of 1000 HZ 3. The kernel must be configured to provide RTC interrupts 4. The kernel must be configured with enhanced real time clock support Remember to use zttest to verify the accuracy of your timing source. The goal is to obtain at least 99.98% output from zttest Regards, Matthew Roth InterMedia Marketing Solutions Software Engineer and Systems Developer
The settings I use are as follows (with explanations):> SLAB Allocator (SLAB or SLUB?)SLAB (the default). I don't know enough about the differences between them to say whether one is better than the other.> Tickless System (?)Enabled. Seems to be the default setting. Disabling it doesn't seem to have any noticeable effect on system performance.> Preemption model (?)Pre-emptable kernel. We want asterisk to be able to interrupt as quickly as possible, even at the expense of overall system efficiency.> IO Scheduler (Anticipatory, Deadline or CFQ?)Deadline. I googled for benchmarks on this a few months ago. There were mutterings about bugs in the Anticipatory scheduler, and not enough detail about CFQ. Deadline is supposed to be best with database loads, and as good as Anticipatory in other environments, whilst being a lot lighter.> Flat or Sparse Memory (?)Flat memory. If you have a system that supports sparse memory, then use it - none of my boxes do.> Timer Frequency (100Hz .. 1000hz)1000hz. The more opportunities for asterisk to generate interrupts the better, I've assumed. Those are the settings I use. Always open to suggestions on improving them :-) Regards, Chris -- C.M. Bagnall, Director, Minotaur I.T. Limited For full contact details visit http://www.minotaur.it This email is made from 100% recycled electrons