Skip to content

Commit d756525

Browse files
committed
Revert "increase memory.max in cgroups.bats"
This reverts commit 65a1074. we need (#4020) because of (#3931), at that time, we removed the bindfd logic, and the memfd logic will use more memory than before, but we have not yet moved binary clone from runc init to runc parent process, so we need to increase memory limit in CI. As we have moved the runc binary clone logic from runc init to runc parent process in (#3987), so the memory usage of binary clone will not be included in container's memory cgroup accounting. Now we can support run a simple container with lower memory usage the same as before. Signed-off-by: lfbzhm <lifubang@acmcoder.com>
1 parent d82235c commit d756525

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

tests/integration/cgroups.bats

+5-5
Original file line numberDiff line numberDiff line change
@@ -303,7 +303,7 @@ convert_hugetlb_size() {
303303
"memory.min": "131072",
304304
"memory.low": "524288",
305305
"memory.high": "5242880",
306-
"memory.max": "20484096",
306+
"memory.max": "10485760",
307307
"pids.max": "99",
308308
"cpu.max": "10000 100000",
309309
"cpu.weight": "42"
@@ -319,14 +319,14 @@ convert_hugetlb_size() {
319319
echo "$output" | grep -q '^memory.min:131072$'
320320
echo "$output" | grep -q '^memory.low:524288$'
321321
echo "$output" | grep -q '^memory.high:5242880$'
322-
echo "$output" | grep -q '^memory.max:20484096$'
322+
echo "$output" | grep -q '^memory.max:10485760$'
323323
echo "$output" | grep -q '^pids.max:99$'
324324
echo "$output" | grep -q '^cpu.max:10000 100000$'
325325

326326
check_systemd_value "MemoryMin" 131072
327327
check_systemd_value "MemoryLow" 524288
328328
check_systemd_value "MemoryHigh" 5242880
329-
check_systemd_value "MemoryMax" 20484096
329+
check_systemd_value "MemoryMax" 10485760
330330
check_systemd_value "TasksMax" 99
331331
check_cpu_quota 10000 100000 "100ms"
332332
check_cpu_weight 42
@@ -368,7 +368,7 @@ convert_hugetlb_size() {
368368
}
369369
| .linux.resources.unified |= {
370370
"memory.min": "131072",
371-
"memory.max": "40484864",
371+
"memory.max": "10485760",
372372
"pids.max": "42",
373373
"cpu.max": "5000 50000",
374374
"cpu.weight": "42"
@@ -383,7 +383,7 @@ convert_hugetlb_size() {
383383

384384
runc exec test_cgroups_unified cat /sys/fs/cgroup/memory.max
385385
[ "$status" -eq 0 ]
386-
[ "$output" = '40484864' ]
386+
[ "$output" = '10485760' ]
387387

388388
runc exec test_cgroups_unified cat /sys/fs/cgroup/pids.max
389389
[ "$status" -eq 0 ]

0 commit comments

Comments
 (0)