How to set systemwide ulimit on ubuntu
13,964
You can set these in /etc/security/limits.conf on Red Hat systems. I think it's the same on Ubuntu. It has examples by default, they're pretty straightforward. Post back if you have problems.
In /etc/security/limits.conf add:
root - core unlimited
* - core unlimited
You will need to log out and log back in before the limits are applied to your session.
Related videos on Youtube
Author by
Admin
Updated on September 17, 2022Comments
-
Admin over 1 year
I want to set systemwide ulimit on ubuntu (all processes, all users).
How can I set it?
thanks
JP
-
Admin over 13 yearsthanks. it looks pretty configurable. I had seen some tutorial where they set "ulimit -s 512" somewhere in rc.d, which limited the mysql and other processes' virtual memory. I forgot where exactly it was done. Is this method equivalent? If so, what is the equivalent setting in limits.conf?
-
BillThor over 13 yearsTry
man limits.conf
to get details on which settings to use. They are also detailed in the header of limits.conf. -
pabouk - Ukraine stay strong over 6 yearsNote that these settings do not really apply system-wide. They apply only to processes spawned from an user session (the user's processes and their children after his login). These limits are set by a PAM module
pam_limits.so
during user's login. --- The processes started byinit
/systemd
(or other alternative) and their children - i.e. system daemons - will not be limited by anything from/etc/security/limits.conf
.