Linked Questions

44 votes
7 answers
72k views

I need to test a process for memory management. I do not have the source, so I need to do all the testing from the OS side. I want to be able to say something like limitmemory 400k -p <pid> Is ...
Lazer's user avatar
  • 36.2k
14 votes
2 answers
38k views

Occasionally some processes on my GNU/Linux desktop (such as gv and gnash) use up the physical memory and cause thrashing. Since these processes aren't important, I want them to be automatically ...
Pteromys's user avatar
  • 453
2 votes
1 answer
1k views

How to setup limit for process to memory usage? Similar to open files limit in /etc/security/limits.conf: ubuntu soft nofile 4096 ubuntu hard nofile 8192 ...
youblind's user avatar
1 vote
1 answer
657 views

I'm running a Ubuntu VM with an 8 GB RAM with docker containers ( 8 GB is just about enough for my requirements) but at some point the VM freezes/crashes due to memory exhaustion leaving me no choice ...
L P's user avatar
  • 111
1 vote
0 answers
304 views

I have an application running under Ubuntu that tries to consume all available memory. Is there a way to specify and restrict the allocations available for a given application?
hat's user avatar
  • 215
0 votes
0 answers
79 views

I routinely perform numerical computations in my laptop, using programs that I write myself in Python, Julia, C++, etc. I am not a perfect programmer (far from it), and I make coding errors frequently....
a06e's user avatar
  • 1,837
30 votes
4 answers
10k views

I have a bash script that sets -e so the script will exit on any exit status != 0. I'm trying to do some basic shell arithmetic assigned to variables and sometimes the expression equals 0 which ...
Dougnukem's user avatar
  • 403
24 votes
3 answers
14k views

There are plenty of questions and answers about constraining the resources of a single process, e.g. RLIMIT_AS can be used to constrain the maximum memory allocated by a process that can be seen as ...
jpe's user avatar
  • 317
17 votes
1 answer
6k views

This article claims that the -m flag to ulimit does nothing in modern Linux. I can find nothing else to corroborate this claim. Is it accurate? You may try to limit the memory usage of a process ...
Flimzy's user avatar
  • 538
10 votes
2 answers
12k views

In the question Limit memory usage for a single Linux process it was mentioned to change the file /etc/default/grub so that GRUB_CMDLINE_LINUX_DEFAULT contains GRUB_CMDLINE_LINUX_DEFAULT="...
Martin Thoma's user avatar
  • 2,912
14 votes
1 answer
10k views

Is there a way my SSH server, and everything under it (including bash) can be always available under heavy load ? Maybe it could be some kind of a critical path, all in memory, with a dedicated CPU ...
blue112's user avatar
  • 667
8 votes
1 answer
7k views

We have a process that in recent weeks had a once-off memory leak that resulted in it consuming all memory on our RHEL 7 box We now wish to set limits around this such that it will never take any ...
DJ180's user avatar
  • 311
10 votes
2 answers
3k views

I have a standard Linux (Debian testing) laptop, with a swap partition. I do a lot of experiments with it. Some of them are really memory hungry and the way Linux behaves by default is an issue for ...
user avatar
5 votes
1 answer
6k views

I'm using Linux on my Steam Deck (SteamOS/Arch Linux). Is there a method to set a hard cap/limit on the maximum total RAM Chrome can use with command line arguments? (to 8 GB out of the device's max ...
JLHack7's user avatar
  • 51
4 votes
1 answer
3k views

I have a Debian 10 server and I am trying to limit the memory + swap of a user using cgroups2. Using memory.limit_in_bytes works fine, but I want to limit the memory+swap using memory.memsw....
Mario's user avatar
  • 181

15 30 50 per page