[systemd-devel] systemd-analyze plot

Lennart Poettering lennart at poettering.net
Mon Jun 27 05:50:01 PDT 2011


On Wed, 22.06.11 14:25, David.Yates at continental-corporation.com (David.Yates at continental-corporation.com) wrote:

> I am currently in the process of analyzing and optimizing a systemd 
> startup in an Embedded project and wondered if someone could tell me what 
> is being performed in the time between 0 and 1 that I see in my plot.svg 
> files produced using systemd-analyze plot.
> 
> Additionally, assuming that this is systemd overhead (dependency 
> creation/module loading) does anyone know of ways to reduce this overhead. 
> I know it is only 1 second but we are always fighting for every 100ms for 
> safety critical applications needed in the early startup phase :-)

This appears to be Fedora, right? So my guess is that this is simply the
initrd. Can you paste the output of "systemctl time" please? that should
tell us how quick the initrd was. (usually it's not the initrd's fault,
really, it's just that the DRI kmods are slow to load, due to monitor
probing and plymouth currently requires to wait for that, although it
really shouldn't).

Ultimately there's a lot we could optimize for systemd here too. For
example, currently when parsing unit files systemd will lookup every
switch linearly in a big table, with strcmps()s. That could relatively
easily be optimized for O(1) with gprof (happy to take such a
patch). But given that this takes 700ms for you (which is extremely
slow, given that we can nowadays boot a full userspace in less than 1s),
I doubt this is the burning issue here.

Lennart

-- 
Lennart Poettering - Red Hat, Inc.


More information about the systemd-devel mailing list