Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Can I limit the system resources that a process can use on Linux? I want to configure the system to avoid that some specified processes use some system resources:

  • choose if a process is allowed to use network and Internet.
  • choose which files and folders that a process can read, write or execute.
  • choose if a process is allowed to use sound and graphics output, and printer.
  • choose the limit of memory that it can use.

I think it is a good solution to run untrusted software without problems.

Thanks

share|improve this question
up vote 0 down vote accepted

The permissions of the user running the process (real user or system user...) should be appropriately set. If you're worried about a process having too much access to the rest of your system's files, can those files be secured with standard permissions? Or change the group of the user to a less permissive one?

Ignacio is on point with his SELinux, as well. Mandatory Access Controls (MAC) are very powerful and robust for this explicit purpose.

Is there a more specific problem that you're thinking of?

share|improve this answer
    
Thanks, I will try SELinux and MAC. – Squall Mar 29 '11 at 1:03

The memory limit can be handled by ulimit. For everything else there's SELinux.

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .