Is it possible to limit a specific user's processes to always run with a niceness of at least 15, say?
Asked
Active
Viewed 143 times
1 Answers
4
You can set per-user or per-group nice values using pam_limits
and the /etc/security/limits.conf
file.
e.g.
username hard priority 15
This only affects PAM services which are configured to use the pam_limits
module. Depending on your distribution, this is probably already enabled for services like login
, cron
, atd
, sshd
, and others. Or you may have to enable it by adding a line like the following to, e.g., /etc/pam.d/login
:
session required pam_limits.so
See man pam_limits
and the comments in /etc/security/limits.conf
for details.
If you have the PAM doc package installed, there may be additional documentation at /usr/share/doc/libpam-doc/html/sag-pam_limits.html

cas
- 78,579