Userspace taking lot of boot time

So in my zorin os lite of the latest version, the boot is taking a lot of time
When i ran system-analyze

So how do i reduce the boot time?
And are there any packages which are making it slower?

Here's a better image

What kind of hardware do you have?

If you don't have dual GPUs (ie: video cards you can switch between... a feature on some laptops... a low-powered GPU for normal use, a higher-powered GPU for gaming), you can get rid of switcheroo...
sudo apt purge switcheroo-control

Do a disk check on /dev/sda3... it's really slow, there might be errors that's slowing enumeration down.

How many snap packages do you have installed? Each snap package installation has to mount just as though a hard drive were being mounted... that's going to slow things down. Uninstall the snap package and install the .deb package for all that you can.

/dev/sda3 is the root disk in which zorin os lite is installed
And i think there are 5 snap packages
How can i check them and remove?

And how do i check device errors?

And i purged
But as per the screenshot i have Intel 4 Series Chipset
So did i did the right thing?

You can check your drive by carefully following the procedure here:

Do not do the destructive read-write test. It'll wipe your Zorin install. Do the non-destructive read-write test.

By doing the non-destructive read-write test, you force the drive to remap any bad sectors it finds (sectors it tries and fails to write to).

You can list your snap packages via:
sudo snap list

After you've found the .deb version of a package, you can uninstall the snap version of that package via:
sudo snap remove {packagename}

So, for instance:
sudo snap remove gimp

1 Like

Yeah... switcheroo only works if you've got more than one GPU. If you've only got one, it loads up and sits there doing nothing.

If your PC's storage is not SSD, it is inevitable that the boot time will be more than a minute.

You can push that envelope by using ZFS and setting up multiple mirrored drives... each drive on a different interface so no one drive maxes out the interface. The bandwidth for reads will be shared amongst the mirrored drives, whereas the write speed will be the same (since it has to write the same data to each mirrored drive)... but you can get around that slow write speed by setting up mirrored SLOG SSD drives.

I get 687 M/s read-speed with three mirrored drives. That's just a bit faster than the average SSD. And I don't have to worry about wear-leveling, bit burnout, etc.


Startup finished in 9.213s (firmware) + 17.555s (loader) + 13.948s (kernel) + 19.586s (userspace) = 1min 304ms reached after 17.559s in userspace

That includes the ~10 second Grub timeout, marked as (firmware).

There are 2 snap packages left which i think , cant be removed

I have also purged the network-dispatcher-service

Give us a sudo systemd-analyze critical-chain... it should be much-improved now.

It should look something like this: @17.559s
└─udisks2.service @13.364s +4.193s
  └─ @13.215s
    └─ @13.214s
      └─zsysd.socket @13.213s
        └─ @13.129s
          └─apparmor.service @12.464s +663ms
            └─ @12.463s
              └─boot-grub.mount @12.460s +2ms
                └─boot-efi.mount @12.382s +58ms
                  └─boot.mount @12.309s +70ms
                    └─ @12.307s
                      └─zfs-import-scan.service @10.314s +1.992s
                        └─systemd-udev-settle.service @3.529s +6.782s
                          └─systemd-udev-trigger.service @3.079s +448ms
                            └─systemd-udevd-kernel.socket @3.014s
                              └─system.slice @1.957s
                                └─-.slice @1.957s

Or, you can do:
systemd-analyze plot > /home/$USER/Desktop/plot.svg
That'll put a graphic on your desktop that is much more detailed.

You can completely uninstall snap (and flatpak)... I have. You have to do it via the traditional sudo apt purge snapd... and you'll likely still have some mounts that you'll have to manually unwind and miscellaneous packages associated with snap to clean up, but it can be done.



Will run it after a reboot

Ah, forgot the caveat on that post... you must do the drive check while booted from the Zorin OS boot USB, not while running the OS from the hard drive(s). Fixed now.

So the time decreased
the sda3 time decreased significantly . But thats is this blueman-service?

The critical chain

The usb drive from which i installed the zorin os lite?

blueman is Bluetooth.