What is the difference between:
a) using the ulimit
command to set a limit on a resource?
b) editing the /etc/security/limits.conf
file for the same purpose?
e.g. what is the entry that should be placed in /etc/security/limits.conf
to account for ulimit -n 8192
?
Is the limit set by ulimit -n 8192
soft or hard?
For whom is it being set?
For the user running the command?
Or it becomes the default entry as if we were using domain=*
in /etc/security/limits.conf
Best Answer
Changes made by
ulimit
will apply only to the current processes. If you need to make them permanent, you must edit/etc/security/limits.conf
About your 3rd question .. it depends what you run on your server, for certain applications you might need a higher number.
ulimit -n
sets soft limit,ulimit -Hn
sets hard limit.