4

This is a problem I always had with Ubuntu 18.04, 19.10 and now with 20.04. I installed the default Ubuntu distro several times, initially in dual boot and then as Ubuntu only, but every time I see that when using Windows the boot is much faster than with Ubuntu.

I own a Lenovo B51-30:

  • 3,8 GB memory
  • Intel Pentium(R) CPU N3710 @ 1.60GHz × 4 processor
  • Intel HD Graphics 405 (BSW) graphics
  • 1TB HDD disk

It had Windows 10 installed by default. I installed Ubuntu via a live USB.

Results of systemd-analyze :

Startup finished in 4.719s (firmware) + 6.054s (loader) + 4.358s (kernel) + 1min 30.230s 
(userspace) = 1min 45.363s 
graphical.target reached after 1min 30.061s in userspace

Results of systemd-analyze critical-chain :

graphical.target @1min 30.061s
└─multi-user.target @1min 30.060s
  └─snapd.seeded.service @56.329s +581ms
    └─snapd.service @33.076s +23.240s
      └─basic.target @31.820s
        └─sockets.target @31.820s
          └─snapd.socket @31.815s +3ms
            └─sysinit.target @31.506s
              └─snapd.apparmor.service @29.550s +1.956s
                └─apparmor.service @27.692s +1.854s
                  └─local-fs.target @27.689s
                    └─run-snapd-ns-canonical\x2dlivepatch.mnt.mount @50.661s
                      └─local-fs-pre.target @6.026s
                        └─systemd-tmpfiles-setup-dev.service @5.257s +769ms
                          └─systemd-sysusers.service @4.604s +650ms
                            └─systemd-remount-fs.service @4.176s +189ms
                              └─systemd-journald.socket @4.063s
                                └─system.slice @4.019s
                                  └─-.slice @4.019s

A friend of mine told me it seems a problem of swap. I noticed that my installation didn't have a swap partition so I created one and activated it with GParted on a live USB:

Screenshot of GParted on my PC

I don't really know what that EFI partition is for, but I noticed my PC has secure-boot enabled and no option in BIOS to disable it, so I wonder if there's some limitation built into the computer.

Adding the swap partition didn't change much, and I didn't add other partitions as like /tmp and /home. Boot time lowered a bit and the critical chain before adding swap was different.

Critical chain before adding swap partition:

Critical chain before adding swap partition

3
  • Great presentation of information - so that's a plus. Apart from it perhaps being a legitimate hardware fault (i.e. running a more lightweight OS might help) - apart from old questions and good guides I would perhaps question run-snapd-ns-canonical\x2dlivepatch.mnt.mount @50.661s - is this 50 second delay?
    – DankyNanky
    May 21, 2020 at 12:50
  • Thanks to the 'old question' you linked I found I set up the swap partition in the wrong way. Thanks to the same old question I solved the issue which followed: kernel time went up to 40 seconds and I solved uncommenting DefaultTimeout in /etc/systemd/system.conf. But the userspace time is still 1:30 minutes and up. I'll read again the 'good guide' and keep searching solutions to the delays. The fact is that every once in a while, and obviously also when I make some change as the one I started the comment with, critical-chain changes, and now I have this: pastebin.com/MXy9EhWZ
    – SamuXzX
    Jun 21, 2020 at 15:01
  • Great, answer your own question!
    – DankyNanky
    Jun 21, 2020 at 21:57

1 Answer 1

1

So it took a long time, just because I didn't have time to solve this. I actually just installed Ubuntu again. This time I didn't use the automatic install, instead I choose to create each partition on my own through the installation tool and I created a swap partition. This time the entire process of make the swap work was done by Ubuntu itself and it seems it went well.

I wrote a lot more previously, but my issue was mainly with swap and it seems solved, so I deleted all the other issue I found in the process and I'll open a ticket with them.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .