RFC how to use kernel procs/threads efficiently

Julian Elischer julian at freebsd.org
Fri Oct 13 14:27:13 UTC 2017


On 10/10/17 8:33 pm, Rick Macklem wrote:
> Julian Elischer wrote:
> [stuff snipped]
>> On 10/10/17 4:25 am, Rick Macklem wrote:
>>> --> As such, having a fixed reasonable # of threads is probably the best
>>>         that can be done.
>>>         - The current patch has the # of threads as a sysctl with a default of 32.
>> why not set it to ncpu or something?
> Well, each of these threads will do an RPC, which means a couple of short
> bursts of CPU and then sleep the rest of the time waiting for the RPC reply
> to come back from the Data Server.
> As such, it would seem to me that you would want a lot more threads than
> CPUs on the machine?
> However, setting the default to "N * ncpu" seems better than just a fixed "32"
> to me. (For nfsd, the current default is 8 * ncpu, so maybe that is a good
> default for this too?)
yeah I really just meant "some function of ncpu"..  not specifically 
"ncpu x 1"
> What do you think?
>
> Thanks for the comment, rick
>
>
>



More information about the freebsd-current mailing list