libpod: move pasta and rootlessport into the conmon cgroup #29823
Should this be renamed? Now, it doesn't move only the common process.
I think the CI failures are related. I just have a naming concern now. Also, the commit message should say Fixes: instead of Closes:.
<img width="1833" height="856" alt="image" src="https://github.com/user-attachments/assets/6a7c90a1-1782-45c7-ac74-954bac07c6f8" />
@giuseppe, Just a heads-up regarding the failing CI checks: the cockpit-revdeps tests are currently failing because the test environment is missing the systemd-container package.
If you look at the bottom of the logs for the browser tests, it fails with:./browser.sh: line 88: systemd-nspawn: command not found
My PR #29803 was hitting this exact same infrastructure failure earlier today, so it has nothing to do with your code changes. The code looks great!
link:https://artifacts.dev.testing-farm.io/e84b398e-901d-4825-be77-02520f2dfd97
[NON-BLOCKING] Packit jobs failed. @podman-container-tools/packit-jobs please check. Everyone else, feel free to ignore.
I think the CI failures are related. I just have a naming concern now. Also, the commit message should sayFixes:instead ofCloses:.
yes, CI failures were related, we need this ugly workaround for now: https://github.com/podman-container-tools/container-libs/pull/1207/changes#r4084790065
Code LGTM,
PTAL @sbrivio-rh
In my issue I suggested libpod-support-<CONTAINER_ID>.scope may be a more accurate name for the control group if it contains more processes, but you may consider this a breaking change. I think keeping the function and control group names in sync is best, i.e., change both or neither.
I've read through most of these changes (excluding vendor/), and everything seems to match what we discussed on the issue. Thanks! I think there are some other related issues, but I'll re-evaluate them once I can test this. Will this only land in a 6.x release?
A friendly reminder that this PR had no activity for 30 days.
@giuseppe, I think the container libs PR has been merged.
Should this also be mentioned in the function's name or comment?
Just one naming comment. Othervise LGTM.
sure.
I've amended the following patch:
diff --git a/libpod/oci_conmon_linux.go b/libpod/oci_conmon_linux.go
index c5ef48fa3f..4414622be9 100644
--- a/libpod/oci_conmon_linux.go
+++ b/libpod/oci_conmon_linux.go
@@ -161,7 +161,8 @@ func (r *ConmonOCIRuntime) withContainerSocketLabel(ctr *Container, closure func
return err
}
-// moveConmonToCgroupAndSignal gets a container's cgroupParent and moves the conmon process to that cgroup
+// moveConmonToCgroupAndSignal gets a container's cgroupParent and moves the conmon process
+// and the per-container network helpers to the conmon cgroup below it
// it then signals for conmon to start by sending nonce data down the start fd
func (r *ConmonOCIRuntime) moveConmonToCgroupAndSignal(ctr *Container, cmd *exec.Cmd, startFd *os.File) error {
// The per-container network helpers belong in the same cgroup as conmon.
LGTM
LGTM
Honny1
giuseppe
When podman owns the conmon cgroup it only ever put conmon there. The per-container network helpers stayed in whatever cgroup the invoking podman happened to live in so their resources were not accounted to the container and their lifetime was tied to an unrelated cgroup.
Put them in the same cgroup as conmon.
Closes: https://github.com/podman-container-tools/podman/issues/29582
Needs: https://github.com/podman-container-tools/container-libs/pull/1207
``
release-note
``None