On Tuesday 01 June 2004 07:27, Surya Srinivasan wrote: > We are planning to use a linux PC as a router in our lab. I was wondering > if anyone has recently measured the forwarding rate using a standard PC > (say Pentium)? Have there been any changes to the kernel to improve the > forwarding rate? > > The best performance I have seen so far is with the Click modular router ( > http://www.pdos.lcs.mit.edu/papers/click:tocs00/paper.pdf ). According to > their study on a 700Mhz Pentium (64 byte packets) > Linux does 75kpps > Linux polling 300kpps (Polling amortizes the device handling overhead over > several packets when packet rates are high is my understanding. It also > avoids the receive livelock issue). > Is receive livelock still an issue with Linux today? Or is this avoided by > throttling the receive interfaces? Newer kernels (2.6.x) use a mechanism known as NAPI which implments interrupt mitigation and related techniques to mitigate this issue. Note that not all NIC device drivers are "NAPIfied" but a lot of them do. NAPI is also present in the 2.4 tree. However, AFAIK there is only a single driver that make use of it there. > > Is there anyone using polling mode for better forwarding rates? I have implemented a system doing this (based on 2.2 kernel and modified Tulip drivers) and was able to sustain line rate forwarding. I believe however that interrupt mitigation techniques as used by NAPI drivers are as efficient a solution. Also, there exist some out of tree drivers by Donald Becker of Scyld that implement interrupt mitigation (for some boards) without NAPI support and that work quite well too. > > I have been looking for documentation in this regard and would appreciate > any pointers. Look for "NAPI Linux" on Google... :-) Hope this helps, Gilad -- Gilad ben-Yossef <gilad@codefidence.com> Codefidence. A name you can trust(TM) http://www.codefidence.com - : send the line "unsubscribe linux-net" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html