On 12/13/2011 12:46 PM, Lennart Poettering wrote: > On Fri, 09.12.11 15:32, Jan Safranek (jsafr...@redhat.com) wrote:
<snip> > Note that this will set up the cgroup structure only during late boot, > which should be fine for most cases. However, in some cases it might > make sense to initialize this due to early boot (for example, to handle > early-boot service, like udev).if you care for those add lines like > the following: > > DefaultDependencies=no > Conflicts=shutdown.target > Before=basic.target shutdown.target I expect that the services that needs cgroups would have "After=cgconfig.service" and systemd will start cgconfig before any of them, regardless how early in the boot it is. In the end I might not need any After/Before in cgconfig.conf at all. Of course, admin must add this "After=cgconfig.service" manually to all dependent services, but he already needs to add "ControlGroup=..." there. I would end up with this simple service in the end: [Unit] DefaultDependencies=no [Service] Type=oneshot RemainAfterExit=yes ExecStart=/sbin/cgconfigparser -l /etc/cgconfig.conf -s 1664 ExecStop=/sbin/cgclear -l /etc/cgconfig.conf -e [Install] WantedBy=sysinit.target Could this work? Jan ------------------------------------------------------------------------------ Systems Optimization Self Assessment Improve efficiency and utilization of IT resources. Drive out cost and improve service delivery. Take 5 minutes to use this Systems Optimization Self Assessment. http://www.accelacomm.com/jaw/sdnl/114/51450054/ _______________________________________________ Libcg-devel mailing list Libcg-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/libcg-devel