mirror of https://github.com/containers/podman.git
libpod: drop warning if cgroup doesn't exist
do not print a warning on cgroup removal if it doesn't exist. Closes: https://github.com/containers/podman/issues/13382 [NO NEW TESTS NEEDED] Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
This commit is contained in:
parent
7877b02aac
commit
e71d497e7c
|
@ -1,3 +1,4 @@
|
||||||
|
//go:build linux
|
||||||
// +build linux
|
// +build linux
|
||||||
|
|
||||||
package libpod
|
package libpod
|
||||||
|
@ -5,6 +6,7 @@ package libpod
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
"fmt"
|
"fmt"
|
||||||
|
"os"
|
||||||
"path"
|
"path"
|
||||||
"path/filepath"
|
"path/filepath"
|
||||||
"strings"
|
"strings"
|
||||||
|
@ -236,7 +238,7 @@ func (r *Runtime) removePod(ctx context.Context, p *Pod, removeCtrs, force bool,
|
||||||
|
|
||||||
// Don't try if we failed to retrieve the cgroup
|
// Don't try if we failed to retrieve the cgroup
|
||||||
if err == nil {
|
if err == nil {
|
||||||
if err := conmonCgroup.Update(resLimits); err != nil {
|
if err := conmonCgroup.Update(resLimits); err != nil && !os.IsNotExist(err) {
|
||||||
logrus.Warnf("Error updating pod %s conmon cgroup PID limit: %v", p.ID(), err)
|
logrus.Warnf("Error updating pod %s conmon cgroup PID limit: %v", p.ID(), err)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue