[systemd-devel] Create complete dependency/boot organization map?
Chris Bell
cwbell at narmos.org
Fri Oct 23 09:33:17 PDT 2015
On 2015-10-23 12:23, Andrei Borzenkov wrote:
> 23.10.2015 19:02, Chris Bell пишет:
>> Hi all,
>>
>> I was wondering, is there any way to create a complete
>> dependency/ordering map for my entire systemd system?
>
> For starting something "systemd --test" shows all static dependencies
> pulled in by startinggiven unit. For stopping something I do not think
> something like this exists.
This provides just a ton of information; far more than what I'm looking
for.
>
>> Basically, I'd
>> like to be able to see, relatively clearly, what targets are reached
>> and
>> when,
>
> Not sure what "when" means. systemd --test dumps jobs that will be
> queued together with dependencies.
Basically in what order are the targets started, and what jobs must
complete before the next target can be started?
>
>> what services are wanted/required by the target, and some
>
> That is also shown by "systemctl list-dependencies".
I use this, but I've found that it's best for analyzing a single unit,
not the overall system.
>
>> dependencies between services. A way to visualize the chain from
>> switch-root.target and default.target.
>>
>
> switch-root.target is challenging because when you run it after boot
> you have rather different unit definitions. It may be possible to
> override it using SYSTEMD_UNIT_PATH but I do not know how to emulate
> /run and /etc. Also results of generators that were running in initrd
> are no more available.
Doesn't have to be from switch-root; I guess from the first 'real'
target once it leaves the initrd.
>
>> I know various functions exist to extract portions of the information
>> I
>> need, and they can be used together to get a complete picture, but I
>> find it difficult to keep everything organized into something
>> ultimately
>> useful. Is there a facility I'm missing? Or is this particular ability
>> too complex to be worth implementing?
To clarify, I'd effectively like to be able to create a visualization of
my boot/init process, in the spirit of how the bootup manpage portrays
the systemd bootup process [0], only with the particulars of my system.
I don't expect it to have the nice graphical flowchart representation,
but some clear representation of that data.
Thanks again!
--Chris
[0] http://www.freedesktop.org/software/systemd/man/bootup.html
More information about the systemd-devel
mailing list