2

I need to apply "ulimit -s 256" to any system thread. Is there any way to achieve this under Ubuntu Server?

SiberianGuy
  • 635
  • 1
  • 8
  • 19

2 Answers2

3

You can set user limits via pam_limits in /etc/security/limits.conf. See man limits.conf for informations about this file.

raphink
  • 11,987
  • 6
  • 37
  • 48
2

On Ubuntu 12.04 /etc/security/limits.conf does not appear to be read unless the following is added to /etc/pam.d/common-session.

session required pam_limits.so

Even then, it's not clear to me if it is picked up for programs started by upstart scripts.

asparagino
  • 183
  • 2
  • 7