Skip to content

Commit 1b659e7

Browse files
authored
Merge pull request #8869 from mqasimsarfraz/release/1.7
[release/1.7] cri: memory.memsw.limit_in_bytes: no such file or directory
2 parents d47069b + b461eca commit 1b659e7

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

pkg/cri/opts/spec_linux_opts.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -330,7 +330,7 @@ func WithResources(resources *runtime.LinuxContainerResources, tolerateMissingHu
330330
s.Linux.Resources.Memory.Swap = &limit
331331
}
332332
}
333-
if swapLimit != 0 {
333+
if swapLimit != 0 && SwapControllerAvailable() {
334334
s.Linux.Resources.Memory.Swap = &swapLimit
335335
}
336336

0 commit comments

Comments
 (0)