h->container_limit_path = h->container_full_path;
} else {
h->cgfd_mon = move_fd(fd_final);
- h->monitor_full_path = move_ptr(path);
}
return true;
if (h->cgfd_mon < 0)
prune = false;
- free_disarm(h->monitor_full_path);
close_prot_errno_disarm(h->cgfd_mon);
}
monitor_cgroup, NULL, false))
continue;
- DEBUG("Failed to create cgroup \"%s\"", maybe_empty(ops->hierarchies[i]->monitor_full_path));
+ DEBUG("Failed to create cgroup %s)", monitor_cgroup);
for (int j = 0; j <= i; j++)
cgroup_tree_prune_leaf(ops->hierarchies[j],
monitor_cgroup, false);
ret = lxc_writeat(h->cgfd_mon, "cgroup.procs", monitor, monitor_len);
if (ret)
- return log_error_errno(false, errno, "Failed to enter cgroup \"%s\"", h->monitor_full_path);
+ return log_error_errno(false, errno, "Failed to enter cgroup %d", h->cgfd_mon);
- TRACE("Moved monitor into %s cgroup via %d", h->monitor_full_path, h->cgfd_mon);
+ TRACE("Moved monitor into cgroup %d", h->cgfd_mon);
if (handler->transient_pid <= 0)
continue;
ret = lxc_writeat(h->cgfd_mon, "cgroup.procs", transient, transient_len);
if (ret)
- return log_error_errno(false, errno, "Failed to enter cgroup \"%s\"", h->monitor_full_path);
+ return log_error_errno(false, errno, "Failed to enter cgroup %d", h->cgfd_mon);
- TRACE("Moved transient process into %s cgroup via %d", h->monitor_full_path, h->cgfd_mon);
+ TRACE("Moved transient process into cgroup %d", h->cgfd_mon);
/*
* we don't keep the fds for non-unified hierarchies around
* - The full path to the container's limiting cgroup. May simply point to
* container_full_path.
*
- * @monitor_full_path
- * - The full path to the monitor's cgroup.
- *
* @version
* - legacy hierarchy
* If the hierarchy is a legacy hierarchy this will be set to
char *container_base_path;
char *container_full_path;
char *container_limit_path;
- char *monitor_full_path;
int version;
/* cgroup2 only */
*/
int cgfd_limit;
- /* File descriptor for the monitor's cgroup @monitor_full_path. */
+ /* File descriptor for the monitor's cgroup. */
int cgfd_mon;
/* File descriptor for the controller's mountpoint @mountpoint. */