[sheepdog] [PATCH] sheep: check resource limit at startup

Liu Yuan namei.unix at gmail.com
Tue Jan 29 05:21:16 CET 2013


On 01/29/2013 12:13 PM, MORITA Kazutaka wrote:
> Exceeding the RLIM_NOFILE value leads to EIO of VMs, doesn't it?  If
> yes, it should be definitely avoided.  Is limiting the number of
> consuming sockfds according to the current RLIM_NOFILE also difficult?
> If we can do it, setting a large value to RLIM_NOFILE doesn't affect
> the sheepdog performance.

Not true for all cases. If it happens to be a eventfd (our local
request), then sheep get problems (such as pusher assume it never fails,
many other thinks too I guess). I am not sure if there are other corner
cases.

Sockfd cache is just one of the FD consumer. There are much more
consumers such as reader and writer, request handler, reclaimer, etc. It
would be nice to handle EMFILE error gracefully for sheep, but before
that, we have to set it to a large enough value to run sheep safely.

Thanks,
Yuan



More information about the sheepdog mailing list