[100583] in RedHat Linux List

home help back first fref pref prev next nref lref last post

Re: limit processes for users

daemon@ATHENA.MIT.EDU (Kevin Smith)
Sat Nov 21 23:56:45 1998

Date: Sat, 21 Nov 1998 23:01:33 -0600 (EST)
From: Kevin Smith <kevin@mtsu.edu>
To: redhat-list@redhat.com
In-Reply-To: <19981120171528.29883.qmail@hotmail.com>
Resent-From: redhat-list@redhat.com
Reply-To: redhat-list@redhat.com

On Fri, 20 Nov 1998, Emmanuel Papirakis wrote:

> Hey,
> 
> 	I am currently trying to pretect my system against such processes:
> 
> void main(){
> 
> 	while(1)
> 		fork();
> 
> }
> 
> 	I know that I should use ulimit -u (a certain numer), but,
> where do I put this so that it becomes in effect for all users 
> (exept root of course) at all times????
> 

Take a look at the nproc option in /etc/security/limits.conf, and add
the following to the tail end of /etc/pam.d/login:

session    required	/lib/security/pam_limits.so

That will let you limit users processes to whatever number you wish, by
inidividual users, groups, or the negation thereof.. :)  enjoy

-----
Kevin Smith
kevin@mtsu.edu

One difference between a man and a machine is that a machine is quiet
when well oiled.


-- 
  PLEASE read the Red Hat FAQ, Tips, Errata and the MAILING LIST ARCHIVES!
		http://www.redhat.com http://archive.redhat.com
         To unsubscribe: mail redhat-list-request@redhat.com with 
                       "unsubscribe" as the Subject.


home help back first fref pref prev next nref lref last post