Page 1 of 2 12 LastLast
Results 1 to 10 of 41

Thread: A Two-Second Boot Time With systemd

Hybrid View

  1. #1
    Join Date
    Jan 2007
    Posts
    15,391

    Default A Two-Second Boot Time With systemd

    Phoronix: A Two-Second Boot Time With systemd

    Lennart Poettering has written a guide for optimizing systemd to the extent that a two-second boot-time or less for this popular free software project...

    http://www.phoronix.com/vr.php?view=MTEwMjc

  2. #2
    Join Date
    Jun 2011
    Posts
    7

    Default

    yep!
    Code:
    $ systemd-analyze time
    Startup finished in 1290ms (kernel) + 5834ms (userspace) = 7125ms
    And this is even with serious services running:
    Code:
    $ systemd-analyze blame
      2449ms mysqld.service
       966ms netfs.service
       793ms NetworkManager.service
       689ms opt.mount
       621ms nxserver.service
       518ms chronyd.service
       505ms httpd.service

  3. #3
    Join Date
    Jun 2010
    Location
    ฿ 16LDJ6Hrd1oN3nCoFL7BypHSEYL84ca1JR
    Posts
    1,052

    Default

    Well, default systemd:


    But aside from that, starting KDE still takes 5+ seconds, even with an SSD. So what's the point for desktop distributions in extremely fast booting when the desktop environment still takes multiple times the boot times to start up?

  4. #4

    Default

    Quote Originally Posted by ChrisXY View Post
    But aside from that, starting KDE still takes 5+ seconds, even with an SSD. So what's the point for desktop distributions in extremely fast booting when the desktop environment still takes multiple times the boot times to start up?
    Um, if my math serves me correctly - your bootup time would be 7 seconds.

    Which is sweet. Much better than what we have today, no?

    Besides, you should see what Martin Graesslin is up to:

    http://blog.martin-graesslin.com/blo...p-performance/

  5. #5
    Join Date
    Jun 2010
    Location
    ฿ 16LDJ6Hrd1oN3nCoFL7BypHSEYL84ca1JR
    Posts
    1,052

    Default

    Quote Originally Posted by halfmanhalfamazing View Post
    Um, if my math serves me correctly - your bootup time would be 7 seconds.
    Which is sweet. Much better than what we have today, no?
    With standard systemd and e4rat with a rotational hard disk my boot was pretty much completely I/O bound. I now use an SSD and in my graph I see very few seconds for the actual boot. psd.service is "profile-sync-daemon" and it copies my firefox profile in a tmpfs. So once the overwhelming majority of my boot time is I/O.

  6. #6
    Join Date
    Jan 2008
    Location
    South Africa
    Posts
    235

    Default

    ChrisXY, if you use the nvidia drivers, it delays X startup by 4 seconds. Could this be extending your KDE startup times?

    I was wondering because on my parents machine (an AMD A6-3500 based system) KDE starts up in about 2 seconds, whereas my old Dell notebook starts KDE in about 8 seconds, and I found half the time it is just waiting for the Nvidia driver to initialize something.

  7. #7
    Join Date
    Jun 2009
    Posts
    2,932

    Default

    Quote Originally Posted by halfmanhalfamazing View Post
    Um, if my math serves me correctly - your bootup time would be 7 seconds.

    Which is sweet. Much better than what we have today, no?
    Debian stable here: 7.57 sec for init (another 9.5 sec for KDE)
    He has 5.8 sec with systemd
    I remember Gentoo's OpenRC to be in that range too, as long as you use ramfs.

    It's better, but let's keep it realistic.

    2 second init is nice, but it's not the major reason for switching to systemd.

  8. #8
    Join Date
    Jul 2010
    Posts
    594

    Default

    Quote Originally Posted by ChrisXY View Post
    But aside from that, starting KDE still takes 5+ seconds, even with an SSD. So what's the point for desktop distributions in extremely fast booting when the desktop environment still takes multiple times the boot times to start up?
    The bootchart in the article shows booting from kernel to complete XFCE desktop in less than two seconds. KDE is bit heavier of course but it could definetly benefit from systemd if the startup script were to be ported to use it. Something like that is probably going to be used in Plasma Active as Mer uses systemd so it might not take that long to come to desktop... or at least I hope so.

    Quote Originally Posted by ChrisXY View Post
    2 second init is nice, but it's not the major reason for switching to systemd.
    I would say that nearly instantaneous boot is pretty damn compelling. Of course many of the other systemd features are even more insteresting but still... If Windows 8 is getting ~10s boot then we can do it five times better. Sounds good to me.

  9. #9
    Join Date
    Jun 2009
    Posts
    2,932

    Default

    Quote Originally Posted by Teho View Post
    I would say that nearly instantaneous boot is pretty damn compelling.
    It's not a near-instantaneous boot, it's a near-instantaneous init.

    Boot goes like this:

    BIOS
    GRUB/lilo
    Kernel
    init <------ this is the part that was cut down from 7 seconds to 2 seconds
    X initialisation
    KDE/GNOME

    The whole boot process is still much longer than 10 seconds.

    It's still impressive work, but some of the comments here are misleading. This is only a part of the boot process.

  10. #10
    Join Date
    Jan 2009
    Posts
    466

    Default

    Quote Originally Posted by pingufunkybeat View Post
    It's not a near-instantaneous boot, it's a near-instantaneous init.

    Boot goes like this:

    BIOS
    GRUB/lilo
    Kernel
    init <------ this is the part that was cut down from 7 seconds to 2 seconds
    X initialisation
    KDE/GNOME
    To make this more generic:

    Hardware/firmware init
    Bootloader
    Kernel
    service init
    Display server
    Window Manager.

    For appliances, we can actually combine the first three (think linux-bios) and do away with the WM in kiosk style implementations.

    For general purpose computing, we can do away with the majority of boot-from-off situations by improving support for sleep/hibernate. Aside from kernel updates, the only reasons I ever boot my systems is due to shortcomings in my OS's sleep/hibernate implementations.

    Look at the iPad as an example. Booting-from-off is a 30-60 second process, but since it has a proper sleep implementation, booting is an extremely rare occurrence.

    F

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •