Restricting Users with ulimit in linux. | extrovert.dev -->

Restricting Users with ulimit in linux.

Restricting Users with ulimit in linux.
Monday, October 23, 2017




Oneway to limit users is by using the ulimit command that is part of the shell.
Typically ulimit commands are placed in /etc/profile so that each user who logsin will execute the commands and set limits on himself. Therefore decide what limits to place on your users and put ulimit commands into /etc/profile.

The most ulimit options are...


  1. -a    Displays all limits 
  2. -c     maximum core file size
  3. -f      maximum file size
  4. -t      maximum CPU time in sec
  5. -n    maximum no of open files
  6. -u    maximum no of processes
-v    maximum amount of virtual memory



This example displays the users limit and then changes the maximum number of open files..

Gspace$ ulimit -a |grep open


    

0 Response to Restricting Users with ulimit in linux.

Comments are personally moderated by our team. Promotions are not encouraged.

Post a Comment