Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 1 addition & 14 deletions _launcher/launcher.R
Original file line number Diff line number Diff line change
Expand Up @@ -203,20 +203,7 @@ launch = function(dt, mockup, out_dir="out") {
if (file.exists(ret_file)) file.remove(ret_file)
}
cmd = sprintf("%s > %s 2> %s", solution.cmd(s, t, d), out_file, err_file) # ./_launcher/solution.R ... > out 2> err
inner = sprintf("/bin/bash -c \"%s%s\"", venv, cmd) # this is needed to source python venv
# Run each solution in its own transient systemd scope so the OOM killer
# targets only that scope and cannot propagate to the R launcher process.
# MemoryMax is set to 90% of total physical RAM.
mem_max = tryCatch({
meminfo = readLines("/proc/meminfo")
total_kb = as.numeric(sub(".*:\\s*(\\d+)\\s*kB", "\\1", meminfo[grepl("^MemTotal", meminfo)]))
total_kb * 1024 * 0.9
}, error = function(e) NA_real_)
if (!is.na(mem_max) && nzchar(Sys.which("systemd-run"))) {
shcmd = sprintf("systemd-run --scope -p MemoryMax=%.0f %s", mem_max, inner)
} else {
shcmd = inner
}
shcmd = sprintf("/bin/bash -c \"%s%s\"", venv, cmd) # this is needed to source python venv
if (mockup) {
cat(cmd)
cat(shcmd)
Expand Down
2 changes: 1 addition & 1 deletion clickhouse/VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
26.4.1.911
26.4.1.1003
2 changes: 1 addition & 1 deletion datafusion/VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
52.3.0
53.0.0
Loading
Loading