diff --git a/CHANGELOG.md b/CHANGELOG.md index 9e06a431bcc..bd827c9c370 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -43,6 +43,7 @@ BUG FIXES: space in it on Windows [[GH-3855](https://github.com/hashicorp/nomad/issues/3855)] * client/vault: Recognize renewing non-renewable Vault lease as fatal [[GH-3727](https://github.com/hashicorp/nomad/issues/3727)] * config: Revert minimum CPU limit back to 20 from 100. + * driver/exec: Properly disable swapping [[GH-3958](https://github.com/hashicorp/nomad/issues/3958)] * driver/lxc: Cleanup LXC containers after errors on container startup. [[GH-3773](https://github.com/hashicorp/nomad/issues/3773)] * ui: Fix ui on non-leaders when ACLs are enabled [[GH-3722](https://github.com/hashicorp/nomad/issues/3722)] * ui: Fix requests using client-side certificates in Firefox. [[GH-3728](https://github.com/hashicorp/nomad/pull/3728)] diff --git a/client/driver/executor/executor_linux.go b/client/driver/executor/executor_linux.go index 37bcb3bfc04..ef1de7ebcf6 100644 --- a/client/driver/executor/executor_linux.go +++ b/client/driver/executor/executor_linux.go @@ -83,7 +83,8 @@ func (e *UniversalExecutor) configureCgroups(resources *structs.Resources) error // Total amount of memory allowed to consume e.resConCtx.groups.Resources.Memory = int64(resources.MemoryMB * 1024 * 1024) // Disable swap to avoid issues on the machine - e.resConCtx.groups.Resources.MemorySwap = int64(-1) + var memSwappiness int64 = 0 + e.resConCtx.groups.Resources.MemorySwappiness = &memSwappiness } if resources.CPU < 2 {