[sheepdog] [PATCH] sheep: avoid the OOM killer

AP sheepdog at inml.weebeastie.net
Sat Jul 6 06:02:45 CEST 2013


On Fri, Jul 05, 2013 at 02:58:22PM +0900, Hitoshi Mitake wrote:
> > > > > +	if (xwrite(fd, "-1000\n", 6) != 6) {
> > > > 
> > > > Please explain what does -1000 means why you choose it.
> > > 
> > > -1000 is OOM_SCORE_ADJ_MIN and this value is for avoiding OOM killer
> > > certainly. I'll add a comment for describing this value in v2.
> > > 
> > 
> > Completely prevent sheep process from being oom-killed? Or just a higher
> > priority to be less likely choosen?
> 
> The value prevents OOM killing completely.

While it's unlikely to change wouldn't it be better to use OOM_SCORE_ADJ_MIN
directly and convert it into a string rather than hardcoding the value in
directly?

AP



More information about the sheepdog mailing list