[systemd-devel] Help regarding priorization of processes at start up
kay.sievers at vrfy.org
Thu Jan 12 08:13:50 PST 2012
On Thu, Jan 12, 2012 at 16:32, George Stefan <stefan.george87 at gmail.com> wrote:
> Thank you for the quick reply. I am not trying to solve any development
> My own problem is something like this: i have a service that is part of this
> graph of dependencies.
> How can i make sure that this service will be processed prior that the other
> ones one the same level.
The order for non-dependent services is not defined.
It's the kernel's scheduler and system calls like communication and
I/O which handles them all in parallel. You can specify nice levels,
I/O priorities, ..., but they will stick for this service the entire
time the service runs. There is currently no process setting that
applies to bootup only.
> This service will also start other services. Will those services be children
> of my first service?
If your service does the fork(), systemd can obviously not know
anything about them. They would be children of your service if they do
not double-fork, if they double-fork, they get re-parented to PID 1,
but that's all out of systemd's control.
If you call systemd to start the services, they will be started
directly by PID1 and be children of PID 1.
> What is the graph traversing method used?
It's just a tree of units, and everything without any further
dependencies is immediately scheduled to start.
> 2012/1/12 Kay Sievers <kay.sievers at vrfy.org>
>> On Thu, Jan 12, 2012 at 15:33, George Stefan <stefan.george87 at gmail.com>
>> > Hello,
>> > I want to implement a dynamic way of starting up services using systemd
>> > immediatly after boot.
>> > So, my question is: Does systemd have an internal list of processes that
>> > are
>> > awaiting to be started?
>> > and is there a way for me to put my own processes ahead of those of
>> > systemd?
>> > If so, were is this list of processes implemented?
>> > I am open to any suggestions.
>> It's just a graph of dependencies, and everything is started as soon
>> as all the dependencies are fulfilled.
>> There is no real other tunable prioritization.
>> What exact problem are you trying to solve?
> systemd-devel mailing list
> systemd-devel at lists.freedesktop.org
More information about the systemd-devel