Re: Killing/balancing processes when overcommited

From: Thunder from the hill (thunder@lightweight.ods.org)
Date: Fri Sep 13 2002 - 05:17:15 EST


Hi,

On Fri, 13 Sep 2002, Giuliano Pochini wrote:
> > ...the last of the user who has the most processes?
>
> No, the last one it's likely to be the sysadmin that
> logged in to try to fix the situation.

Not exactly.

if (we run oom) {
        if (we find a malloc() eater) {
                kill it;
        } else if (there's an ->user<- who forked lots of processes) {
                kill some;
        } else {
                kill randomly, based on some table, or whatever...;
        }
}

Means we only kill processes if (task->euid) in the second stage. Malloc
eaters are likely to be system jobs (such as data servers), so we better
don't check the UID then.

                        Thunder

-- 
--./../...-/. -.--/---/..-/.-./..././.-../..-. .---/..-/.../- .-
--/../-./..-/-/./--..-- ../.----./.-../.-.. --./../...-/. -.--/---/..-
.- -/---/--/---/.-./.-./---/.--/.-.-.-
--./.-/-.../.-./.././.-../.-.-.-

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Sun Sep 15 2002 - 22:00:32 EST