performance – How to investigate a slow boot time after a hdd removal

I recently removed a hard drive from my system. Now there is a 30s delay when booting my Ubuntu 20.04.1.

It generally boots up in around 10s, but since I removed the old hdd, it takes 30 more seconds to boot up. This is after the grub menu and seems to be in the kernel time:

$ systemd-analyze time
Startup finished in 33.346s (kernel) + 7.865s (userspace) = 41.212s reached after 7.859s in userspace

After I hit “Enter” in grub and before I see the logo and spinning thingy, 30s elapse…

With dmesg I see a 30s gap but I don’t know what happens during this gap …

$ dmesg
(    2.146323) input: Logitech USB Keyboard Consumer Control as /devices/pci0000:00/0000:00:14.0/usb1/1-10/1-10.1/1-10.1:1.1/0003:046D:C31C.0003/input/input4
(    2.204160) input: Logitech USB Keyboard System Control as /devices/pci0000:00/0000:00:14.0/usb1/1-10/1-10.1/1-10.1:1.1/0003:046D:C31C.0003/input/input5
(    2.204365) hid-generic 0003:046D:C31C.0003: input,hidraw2: USB HID v1.10 Device (Logitech USB Keyboard) on usb-0000:00:14.0-10.1/input1
(   33.254756) fbcon: Taking over console
(   33.254828) Console: switching to colour frame buffer device 240x67
(   33.275845) EXT4-fs (sda1): mounted filesystem with ordered data mode. Opts: (null)