Very slow startup and shutdown speeds

Firstly, here are some outputs you may refer to.

Output of systemd-analyze:

[user@endeavourOS ~]$ systemd-analyze
Startup finished in 7.046s (firmware) + 1.826s (loader) + 1.858s (kernel) + 1.561s (userspace) = 12.291s 
graphical.target reached after 1.561s in userspace

Output of systemd-analyze blame:

[user@endeavourOS ~]$ systemd-analyze blame
3.625s udisks2.service
 754ms systemd-random-seed.service
 490ms systemd-fsck@dev-disk-by\x2duuid-c48dd7dd\x2db99e\x2d412b\x2dad62\x2df3c4ec2d0e5b.service
 434ms dev-nvme0n1p7.device
 420ms user@1000.service
 157ms power-profiles-daemon.service
 156ms systemd-journal-flush.service
  91ms NetworkManager.service
  85ms upower.service
  84ms systemd-udev-trigger.service
  76ms systemd-rfkill.service
  67ms systemd-fsck@dev-disk-by\x2duuid-A796\x2dA455.service
  65ms avahi-daemon.service
  64ms home.mount
  60ms polkit.service
  48ms systemd-logind.service
  44ms systemd-udevd.service
  42ms systemd-journald.service
  38ms systemd-tmpfiles-setup.service
  36ms systemd-timesyncd.service
  25ms systemd-update-utmp.service
  24ms boot-efi.mount
  24ms lvm2-monitor.service
  21ms systemd-tmpfiles-setup-dev.service
  19ms systemd-modules-load.service
  19ms alsa-restore.service
  13ms dev-hugepages.mount
  13ms modprobe@fuse.service
  12ms dev-mqueue.mount
  12ms sys-kernel-debug.mount
  11ms wpa_supplicant.service
  11ms tmp.mount
  11ms sys-kernel-tracing.mount
  11ms dev-nvme0n1p6.swap
  10ms kmod-static-nodes.service
  10ms systemd-binfmt.service
   9ms systemd-backlight@backlight:acpi_video0.service
   9ms systemd-remount-fs.service
   9ms modprobe@configfs.service
   9ms systemd-backlight@backlight:amdgpu_bl0.service
   8ms modprobe@drm.service
   8ms user-runtime-dir@1000.service
   5ms kill_kwin.service
   5ms systemd-sysctl.service
   4ms systemd-user-sessions.service
   3ms sys-fs-fuse-connections.mount
   2ms sys-kernel-config.mount
   1ms proc-sys-fs-binfmt_misc.mount

Output of systemd-analyze critical-chain:

[user@endeavourOS ~]$ systemd-analyze critical-chain
The time when unit became active or started is printed after the "@" character.
The time the unit took to start is printed after the "+" character.

graphical.target @1.561s
└─multi-user.target @1.561s
  └─power-profiles-daemon.service @1.403s +157ms
    └─basic.target @1.385s
      └─sockets.target @1.385s
        └─dbus.socket @1.385s
          └─sysinit.target @1.357s
            └─systemd-backlight@backlight:amdgpu_bl0.service @1.500s +9ms
              └─system-systemd\x2dbacklight.slice @1.496s
                └─system.slice @186ms
                  └─-.slice @186ms

Output of neofetch:


                    ./o.                  user@endeavourOS  
                  ./sssso-                -----------------                                                                                                                                                                                 
                `:osssssss+-              OS: EndeavourOS Linux x86_64                                                                                                                                                                      
              `:+sssssssssso/.            Host: HP Laptop 15s-gr0xxx                                                                                                                                                                        
            `-/ossssssssssssso/.          Kernel: 5.16.3-zen1-1-zen                                                                                                                                                                         
          `-/+sssssssssssssssso+:`        Uptime: 16 mins                                                                                                                                                                                   
        `-:/+sssssssssssssssssso+/.       Packages: 1081 (pacman)                                                                                                                                                                           
      `.://osssssssssssssssssssso++-      Shell: bash 5.1.16                                                                                                                                                                                
     .://+ssssssssssssssssssssssso++:     Resolution: 1920x1080                                                                                                                                                                             
   .:///ossssssssssssssssssssssssso++:    DE: Plasma 5.23.5                                                                                                                                                                                 
 `:////ssssssssssssssssssssssssssso+++.   WM: KWin                                                                                                                                                                                          
`-////+ssssssssssssssssssssssssssso++++-  Theme: Breeze Light [Plasma], Breeze [GTK2/3]                                                                                                                                                     
`..-+oosssssssssssssssssssssssso+++++/`   Icons: [Plasma], breeze-dark [GTK2/3]                                                                                                                                                             
  ./++++++++++++++++++++++++++++++/:.     Terminal: konsole                                                                                                                                                                                 
 `:::::::::::::::::::::::::------``       CPU: AMD Ryzen 3 3250U with Radeon Graphics (4) @ 2.600GHz                                                                                                                                        
                                          GPU: AMD ATI Radeon Vega Series / Radeon Vega Mobile Series  
                                          Memory: 1629MiB / 13989MiB

I had Xfce4 as the default DE earlier, which gave me good startup and shutdown speeds, of around 6-8s (excluding GRUB countdown). I recently did a fresh install of EOS with KDE Plasma, and the startup and shutdown speeds have gone to around 10-15s (excluding GRUB countdown). This is an SSD, and it’s surprising because even Windows 11 boots faster. For shutdown, it takes around 10 seconds to complete, meaning that for 10-12 seconds after hitting “Shut Down”, all I see is my wallpaper and the mouse cursor and then it goes black and boots off.

Most of the time during boot is taken in the place where normally the Splash Screen would appear. I have disabled it, so in place of that, I see a blank black screen for 10 seconds. This is followed by 2-3 seconds wherein everything is loading step-by-step.

Anything I can do to bring the time down?

EDIT:
I followed the method in this post: https://www.reddit.com/r/ManjaroLinux/comments/oq2aez/fix_for_slow_shutdown_and_reboot_on_manjaro_kde/
And in this comment: https://www.reddit.com/r/ManjaroLinux/comments/oq2aez/comment/h94kqon/?utm_source=share&utm_medium=web2x&context=3
But it didn’t work.

1 Like

A full 12 seconds?! Very slow indeed.

No, I dont think so. 12 seconds is already very fast for a laptop.

The desktop environment, plasma/xfce, has no significant influence on the boot time.

From the 12 seconds boot time your laptop spends 7 seconds right at the beginning in the firmware (hardware detection, RAM timing etc.). And it spends the next 2 seconds in the loader (grub). That leaves only 3 seconds for you to optimize in Linux. There is very little to gain.

I would not consider that a very slow startup. But, you can see your slowest process is the udisk2 and a google search brings me here for potential optimization https://unix.stackexchange.com/questions/586715/speeding-up-udisks2-service-in-linux

Excuse me, but is 12 seconds your real boot time because it is already good and most time is spent on firmware so there is mot much to do about it or is there another bottleneck that does not show up on systemd-analyze output (like the desktop environment) ?

If it is the 1st case, https://wiki.archlinux.org/title/EFISTUB may add a second or two by bypassing the bootloader.

Also use inxi -Faz for sending system info, not neofetch.

1 Like

The 10-12 seconds I mentioned are very loose, something that I counted on my fingers to estimate the boot time.

As I mentioned in the post, the step where the “Splash Screen” appears, is what takes most of the time. I have disabled Splash Screen via settings, but that “step” wherein I have to wait for 10 seconds persists.

The boot process goes something like this; button is pressed, after 3 seconds GRUB shows up, I choose EOS, I have to wait 3-4 seconds, then the login screen asks for the password, I enter the password (exclude the time here), after this I see a black screen for exactly 10 seconds, after this I see my wallpaper and the cursor nothing else, the system takes around 5 seconds to load everything, after this, I am able to use it.

In case of the Shutdown; I click the button, everything vanishes, just my wallpaper and cursor for 10 seconds, and then the system boots off.

Will use inxi -Faz next time. My apologies.

I believe the numbers in the output aren’t accurate. Please read my reply in this thread: Very slow startup and shutdown speeds - #6 by BrokenToast

This has nothing to do with system boot and all the numbers you are showing. What you are ddescribing here is the login / logout to KDE plasma. And that indeed can take a few seconds and it is certainly slower than XFCE what you used before.

So your question is better asked as a KDE plasma slowness than a slow system startup.

Is there anything that can be done to speed it up?

I experienced the exact same situation on Garuda. Switchimg to wayland magically solved the issue for me. I still don’t know why.
Install plasma-wayland-session package and log out, you will see the wayland option.

1 Like

Hello,

Thanks for the reply, installing plasma-wayland-session solved the shutdown problem. The loading at boot is still there, but I guess I’ll just excuse it.

Thanks once again.

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.