File descriptor: Difference between revisions

From Q
Jump to navigation Jump to search
Tgurr (talk | contribs)
Created page with "== Global limit == === Display === {{Root|cat /proc/sys/fs/file-max}} === Change === {{File|/etc/sysctl.conf| <pre> fs.file-max = 65536 </pre> }} Apply the changes made in s..."
 
Tgurr (talk | contribs)
No edit summary
Line 27: Line 27:


The soft limit is the value a user starts with after login and the hard limit is the value a user is allowed to raise the value to.
The soft limit is the value a user starts with after login and the hard limit is the value a user is allowed to raise the value to.
Changes can be made by running {{Command|ulimit -n 8192}}.
Changes can be made with {{Command|ulimit -n 8192}}

Revision as of 17:04, 23 May 2013

Global limit

Display

# cat /proc/sys/fs/file-max

Change

File: /etc/sysctl.conf
fs.file-max = 65536

Apply the changes made in sysctl.conf.

# sysctl -p

Per-user limit

Display

# ulimit -n

Change

File: /etc/securitty/limits.conf
username soft nofile 4096
username hard nofile 16384

Instead of username you can also use * as a wildcard.

The soft limit is the value a user starts with after login and the hard limit is the value a user is allowed to raise the value to.

Changes can be made with

$ ulimit -n 8192