You are not logged in.
I have a bunch of data sets and I run the same computation on each data set. I want to measure the runtime of each executed task (computation on a given data set).
When a task tries to use more memory than is available in RAM, I would like the kernel to kill it with an out of memory error, and to start the execution of the next task.
My first idea to achieve this was to turn swap off, so the process cannot use more memory than available in RAM.
However, what happens is that when the memory-hungry task exceeds the memory limit, my system crashes, reboots, and runs `systemd-coredump` to restore the crashed process. It then continues running the memory-hungry process.
I would like to achieve the following:
1. The memory-hungry process should not crash the system, the system should kill the process.
2. I don't want to let the process use swap space.
3. I don't want to impose a strict time limit on the execution of any task (I don't know how long they can run).
What would be your ideas?
Offline
Please post the system journal showing the crash, reboot and systemd-coredump.
Offline
What are you interested in, in particular?
Can you please elaborate a bit more.
Offline
What are you interested in, in particular?
All of it....
https://bbs.archlinux.org/viewtopic.php?id=57855
Offline
Why the system crashes, what after the reboot starts the task again, what the systemd-coredump was for.
Offline
You can try fencing the processes with cgroups https://wiki.archlinux.org/index.php/cgroups
Offline
Jin, Jîyan, Azadî
Offline
Or jail it in a https://wiki.archlinux.org/index.php/Cg … urce_usage
However
my system crashes, reboots, and runs `systemd-coredump` to restore the crashed process. It then continues running the memory-hungry process.
sounds fairly exotic and not like something that "just happens"…
Offline
Why are you counting on the kernel to kill your process ? Why not check if you have enough memory available within your computation and if you don't make a clean exit. For instance, using plain F90:
INTEGER :: STATUS
ALLOCATE(ARRAY(DIM1,DIM2,...),STAT=STATUS)
IF (STATUS > 0) THEN
!! Do this
ELSE
!! Do that
ENDIF
Last edited by fistrosan (2021-02-03 11:16:41)
Offline