Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I want to increase the buffer size for network interface card to handle large concurrency. With ethtool I have set the buffer size to 4096 KB. But I want to increase more. Is that possible, and what should I do?

share|improve this question

migrated from stackoverflow.com May 17 '11 at 12:56

This question came from our site for professional and enthusiast programmers.

2  
Is it really necessary (are you seeing dropped packets)? The TCP/IP protocol stack almost certainly does its own buffering in addition to the receive buffer for the nic. –  davmac May 17 '11 at 4:45
    
To tell the truth I am not sure. But when I change the buffer size from default value to 4096KB, the time cost of handling 150 thousand concurrent short connections (not strictly concurrent, simulated by 5 clients each of which sending 30 thousand requests) reduces from 15 seconds to 6 or 7 seconds. I was stuck here and I excepted more improvement. Thank you. –  zidianqs May 21 '11 at 7:43

1 Answer 1

The NIC ring buffer maximum size is determined by how much memory is available on the NIC. Typically you do not adjust this setting, this is very much a system administration task and an advanced one at that. 4MB is quite large for a NIC ring buffer. Intel NICs tend to cap at this amount. Broadcom NICs tend to cap at less than one quarter that amount, 1020KB. It is extremely unlikely, unless you have a 10GigE NIC, that you can go above 4096KB in the NIC's internal ring buffer. But we would need the exact model to know for sure as it is a hardware limitation.

http://www.scottalanmiller.com/linux/2011/06/20/working-with-nic-ring-buffers/

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.