Re: prevent out of memory
Date: 1 Aug 2004 20:46:36 -0700
Michael Heiming <michael+USENET@www.heiming.de> wrote in message news:<email@example.com>...
> > maximum memory usage per process needs to be less than available
> > memory. So if you have 8GB of RAM+swap you must give each user, for
> > example, a max of 1G/process and 8 processes, or 128MB per process and
> > 64 processes.
> And don't forget to restrict max logins, as those limits are per
> login. Anyway I don't see where those are not suitable? Sure it's
> a little configuration and mostly used to stop people from being
> able to bring the system to a grinding halt with some fork bomb.
I see your confusion now. These limits are not per login. The rlimits
related to process size are per *process*.
This is why they do not work to prevent a user from running the system
out of memory. The user can run multiple processes.
While the number of processes a *user* can run can also be limited, a
reasonably large limit must be set.