3

For

systemd-analyze && systemd-analyze blame | head && systemd-analyze critical-chain && echo

When USB drive is attached:

Startup finished in 1.818s (kernel) + 50.866s (userspace) = 52.685s
graphical.target reached after 50.785s in userspace
         50.254s dev-mmcblk0p2.device
          5.192s systemd-udev-settle.service
           944ms [email protected]
           501ms systemd-journal-flush.service
           428ms networkd-dispatcher.service
           419ms acct.service
           325ms apport.service
           315ms systemd-udev-trigger.service
           301ms sysstat.service
           300ms hddtemp.service
The time after the unit is active or started is printed after the "@" character.
The time the unit takes to start is printed after the "+" character.

graphical.target @50.785s
└─multi-user.target @50.773s
  └─getty.target @50.761s
    └─[email protected] @50.749s
      └─dev-ttyAML0.device @50.724s

When USB drive is unplugged:

Startup finished in 1.833s (kernel) + 3.249s (userspace) = 5.082s
graphical.target reached after 3.191s in userspace
          1.205s dev-mmcblk1p2.device
           822ms [email protected]
           534ms blk-availability.service
           474ms systemd-journal-flush.service
           464ms apport.service
           423ms networkd-dispatcher.service
           398ms systemd-udev-settle.service
           345ms systemd-logind.service
           325ms lm-sensors.service
           295ms systemd-udev-trigger.service
The time after the unit is active or started is printed after the "@" character.
The time the unit takes to start is printed after the "+" character.

graphical.target @3.191s
└─multi-user.target @3.179s
  └─postfix.service @3.147s +18ms
    └─[email protected] @2.300s +822ms
      └─basic.target @2.208s
        └─sockets.target @2.196s
          └─acpid.socket @2.182s
            └─sysinit.target @2.039s
              └─systemd-update-utmp.service @1.913s +19ms
                └─systemd-tmpfiles-setup.service @1.780s +58ms
                  └─local-fs.target @1.743s
                    └─media-boot.mount @1.674s +57ms
                      └─dev-disk-by\x2duuid-F702\x2d39CB.device @1.623s

currently the USB drive has

usb-storage.quirks=0bc2:ab38:,0bc2:2022:,0bc2:3312:u"

to make SMART work.

Other USB drives I have don't cause this issue...

So is there some way to tell systemd to not wait for select drives on boot?

Edit:

https://www.systutorials.com/docs/linux/man/5-systemd.device/

indicates maybe adding

SYSTEMD_READY=0

to

/etc/udev/rules.d/99-local.rules

somehow... udevadm monitor output is long and I don't know my udev rules. Timing wise maybe one of these

KERNEL[2185.507867] add      /devices/platform/soc/ffe09000.usb/ff500000.usb/xhci-hcd.0.auto/usb2/2-1/2-1.1/2-1.1.2/2-1.1.2.1/2-1.1.2.1:1.0/host1/target1:0:0 (scsi)
KERNEL[2185.507927] add      /devices/platform/soc/ffe09000.usb/ff500000.usb/xhci-hcd.0.auto/usb2/2-1/2-1.1/2-1.1.2/2-1.1.2.1/2-1.1.2.1:1.0/host1/target1:0:0/1:0:0:0 (scsi)
KERNEL[2185.507968] add      /devices/platform/soc/ffe09000.usb/ff500000.usb/xhci-hcd.0.auto/usb2/2-1/2-1.1/2-1.1.2/2-1.1.2.1/2-1.1.2.1:1.0/host1/target1:0:0/1:0:0:0/scsi_device/1:0:0:0 (scsi_device)
KERNEL[2185.508051] add      /devices/platform/soc/ffe09000.usb/ff500000.usb/xhci-hcd.0.auto/usb2/2-1/2-1.1/2-1.1.2/2-1.1.2.1/2-1.1.2.1:1.0/host1/target1:0:0/1:0:0:0/scsi_disk/1:0:0:0 (scsi_disk)
KERNEL[2185.508203] add      /devices/platform/soc/ffe09000.usb/ff500000.usb/xhci-hcd.0.auto/usb2/2-1/2-1.1/2-1.1.2/2-1.1.2.1/2-1.1.2.1:1.0/host1/target1:0:0/1:0:0:0/bsg/1:0:0:0 (bsg)

vs the much later

KERNEL[2209.775922] add      /devices/platform/soc/ffe09000.usb/ff500000.usb/xhci-hcd.0.auto/usb2/2-1/2-1.1/2-1.1.1/2-1.1.1:1.0/host0/target0:0:0/0:0:0:0/block/sda/sda1 (block)

0

You must log in to answer this question.

Browse other questions tagged .