User Kernel Limits

less than 1 minute read

title: “Linux User and Kernel limits” permalink: /posts/Linux-user-kernel-limits/ classes: wide header: teaser: “/assets/images/linux-virtual-filesystem.jpeg” categories:

  • Operating system tags:
  • ulimit
  • Process resources management

User Process

ulimit is a built-in command that can use to limit the resources used by per-user processes.

[email protected]:~$ ulimit -a
core file size          (blocks, -c) 0
data seg size           (kbytes, -d) unlimited
scheduling priority             (-e) 0
file size               (blocks, -f) unlimited
pending signals                 (-i) 3697
max locked memory       (kbytes, -l) 16384
max memory size         (kbytes, -m) unlimited
open files                      (-n) 1024
pipe size            (512 bytes, -p) 8
POSIX message queues     (bytes, -q) 819200
real-time priority              (-r) 0
stack size              (kbytes, -s) 8192
cpu time               (seconds, -t) unlimited
max user processes              (-u) 3697
virtual memory          (kbytes, -v) unlimited
file locks                      (-x) unlimited

Daemon or running services

ulimit will not be able to limit the resources utilization of daemon or running process. We can attach process using gdb and use setrlimit system call

Updated:

Leave a comment