mirror of
https://github.com/k3s-io/kubernetes.git
synced 2026-01-04 23:17:50 +00:00
Ensure panic_on_oom disabled
This commit is contained in:
@@ -23,7 +23,14 @@ import (
|
||||
"strings"
|
||||
)
|
||||
|
||||
const sysctlBase = "/proc/sys"
|
||||
const (
|
||||
sysctlBase = "/proc/sys"
|
||||
VmOvercommitMemory = "vm/overcommit_memory"
|
||||
VmPanicOnOOM = "vm/panic_on_oom"
|
||||
|
||||
VmOvercommitMemoryAlways = 1 // kernel performs no memory over-commit handling
|
||||
VmPanicOnOOMInvokeOOMKiller = 0 // kernel calls the oom_killer function when OOM occurs
|
||||
)
|
||||
|
||||
// GetSysctl returns the value for the specified sysctl setting
|
||||
func GetSysctl(sysctl string) (int, error) {
|
||||
|
||||
Reference in New Issue
Block a user