[systemd-devel] Questions about systemd-run

Heran Yang herany1999 at gmail.com
Wed Jun 5 02:06:15 UTC 2024


Hi,

I'm trying to leverage systemd-run to build a utility like GNU time. But I
ran into some problems.

1. Behaviour on memory accounting isn't consistent, please see the issue on
Github[1]. And I found that even if I add the property `MemoryAccouting` to
the command, it won't help.
2. When the process exits, the corresponding cgroup is deleted. But the
document[2] says: Simply watch for state changes until this state is
reached, then read the status details from the various properties you need.
So is the status here systemd provides? I think we can preserve the cgroup
and delete it when the services/scope is killed, which can be much better.

I'm a beginner in systemd area, so if I have any mistakes, please point
them out and let me know. Thanks.

[1] https://github.com/systemd/systemd/issues/33191
[2] https://systemd.io/CONTROL_GROUP_INTERFACE/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/systemd-devel/attachments/20240605/961d351d/attachment.htm>


More information about the systemd-devel mailing list