[arch-general] lvm2-monitor and packagekit seem to give long boot times

Mike Cloaked mike.cloaked at gmail.com
Sun Jul 18 15:22:32 UTC 2021


On a laptop which was previously booting acceptably fast, in  recent days
it has been booting very slowly.  I ran the boot analysis:

$ sudo systemd-analyze blame
6.216s packagekit.service
5.664s lvm2-monitor.service
4.532s initrd-switch-root.service
3.694s cups.service
3.016s ldconfig.service
2.744s systemd-logind.service
2.507s systemd-hwdb-update.service

Has anyone else seen packagekit and lvm2-monitor services causing slow boot
times?  There were threads from a couple of years ago where people had
problems with lvm2-monitor, and if lvm was not being used, masking that
service helped boot times improve (and shutdown times too.

So I masked the lvm2-monitor service and the boot time is significantly
improved:

$ sudo systemd-analyze blame
1.722s cups.service
 941ms initrd-switch-root.service
 586ms systemd-journal-flush.service
 529ms systemd-udevd.service
 364ms packagekit.service

I also found past threads that suggested that pacman 6 possibly causes some
issues with packagekit,  so I followed a suggestion to do:

$ sudo rm -fr /var/lib/PackageKit/alpm
$ sudo systemctl restart packagekit

The shutdown time was taking over a minute prior to this, but seems to be
improved after cleaning up the packagekit alpm directory.  If anyone else
has found similar issues and has any workaround to clean things up it would
be useful to know about how it was done. These issues have occurred on two
old laptops, but not on  a relatively new laptop, so possibly some old
files from previous versions of packages may have  been underlying these
issues.

Are there any other cleanup suggestions that are needed to completely
resolve this slow boot and shutdown issues that anyone is aware of?
-- 
mike c


More information about the arch-general mailing list