1

Can you explain me the relation of ulimit setting on a proccess and line

session required pam_limits.so

in pam module. In wich modules i really require this line?

I have this line in pam.d/su pam.d/sudo Do I require it in common-session as suggested this post for example:

https://askubuntu.com/questions/162229/how-do-i-increase-the-open-files-limit-for-a-non-root-user.

And why do I require it if i do ? )

And one more question: if i have

root            soft    nofile  8192
root            hard    nofile  8192

in /etc/security/limits.conf it automatically forbids setting all nofile ulimits for other users that wants more open files than 8192 and are allowed to do this by file in /etc/security/limits.d/ directory ?

Why does this happen ?

If i don't have directives in /etc/security/limits.conf and spawn a program in a shell that drop's it's privileges everything is right: process has nofile 65535 files open. But if i add

root            soft    nofile  8192
root            hard    nofile  8192

why the process can't grab it's own limits? I know that the process should inherits all limits from parent, but why in this case it is possible for a process to get higher privileges, than defaults of root when no root has no explicitly limited in /etc/security/limits.conf ?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.