Difference between revisions of "Ulimit"
m |
|||
(2 intermediate revisions by one other user not shown) | |||
Line 1: | Line 1: | ||
+ | [[Category:Basics]] | ||
== General == | == General == | ||
ulimit is a tool to print and control user limits on a Linux system | ulimit is a tool to print and control user limits on a Linux system | ||
Line 5: | Line 6: | ||
The ulimit command line tool allows to print the user limits for certain recources within the current shell: | The ulimit command line tool allows to print the user limits for certain recources within the current shell: | ||
− | $ ulimit -a | + | $ ulimit -a |
Furthermore, the ulimit command can be used to set a limit to a differnt value. | Furthermore, the ulimit command can be used to set a limit to a differnt value. | ||
Line 11: | Line 12: | ||
1. When a program uses more memory for the stack than allowed, this leads to a SEGFAULT during execution of the program. This happens quite often for Fortran programs. In such cases increasing the stacksize with one of the following commands can help: | 1. When a program uses more memory for the stack than allowed, this leads to a SEGFAULT during execution of the program. This happens quite often for Fortran programs. In such cases increasing the stacksize with one of the following commands can help: | ||
− | $ ulimit -s 100000 | + | $ ulimit -s 100000 |
− | or | + | or |
− | $ ulimit -s unlimited | + | $ ulimit -s unlimited |
2. On frontend nodes often a timelimit is set for processes to avoid that people start long running applications and distub other users. For IDEs or debuggers this can be a bad idea, since the limit might kill the debugger or the IDE after some time without any warning or message. In such cases deactivating the timelimit before starting the IDE is useful: | 2. On frontend nodes often a timelimit is set for processes to avoid that people start long running applications and distub other users. For IDEs or debuggers this can be a bad idea, since the limit might kill the debugger or the IDE after some time without any warning or message. In such cases deactivating the timelimit before starting the IDE is useful: | ||
− | $ ulimit -t unlimited | + | $ ulimit -t unlimited |
Latest revision as of 09:23, 5 September 2019
General
ulimit is a tool to print and control user limits on a Linux system
Manual
The ulimit command line tool allows to print the user limits for certain recources within the current shell:
$ ulimit -a
Furthermore, the ulimit command can be used to set a limit to a differnt value. The most frequent cases when this is needed is: 1. When a program uses more memory for the stack than allowed, this leads to a SEGFAULT during execution of the program. This happens quite often for Fortran programs. In such cases increasing the stacksize with one of the following commands can help:
$ ulimit -s 100000 or $ ulimit -s unlimited
2. On frontend nodes often a timelimit is set for processes to avoid that people start long running applications and distub other users. For IDEs or debuggers this can be a bad idea, since the limit might kill the debugger or the IDE after some time without any warning or message. In such cases deactivating the timelimit before starting the IDE is useful:
$ ulimit -t unlimited