How to use the ulimit command in LINUX
Editor to share with you how to use the ulimit command in LINUX, I believe most people do not know much about it, so share this article for your reference, I hope you can learn a lot after reading this article, let's go to know it!
Ulimit is used to limit the resources consumed by the shell startup process, supporting the following types of restrictions: the size of kernel files created, the size of process data blocks, the size of files created by Shell processes, the size of memory locks, the size of resident memory sets, the number of open file descriptors, the maximum size of the allocation stack, CPU time, the maximum number of threads per user, and the maximum virtual memory that can be used by Shell processes. At the same time, it supports the limitation of hard resources and soft resources.
As a temporary restriction, ulimit can act on shell sessions logged in by using its commands, ending the restriction when the session terminates, without affecting other shell sessions. For long-term fixed limits, ulimit command statements can be added to files read by login shell, acting on specific shell users.
Grammar
Ulimit (option) option
-a: show the current resource limit setting;-c: set the maximum value of the core file in chunks;-d: the maximum value of the program data section area, in KB;-f: shell can create the largest file, in chunks;-H: set the hard limit of resources, that is, the limit set by the administrator;-m: specify the upper limit of available memory in KB -n: specify the maximum number of files that can be opened at a time;-p: specify the size of the pipeline buffer (in 512 bytes);-s: specify the upper limit of stack (in KB;-S): set the elastic limit of resources;-t: specify the upper limit of CPU usage time (in seconds);-u: the maximum number of programs that users can open;-v: specify the upper limit of available virtual memory (in KB). The above is all the contents of the article "how to use ulimit commands in LINUX". Thank you for reading! I believe we all have a certain understanding, hope to share the content to help you, if you want to learn more knowledge, welcome to follow the industry information channel!