Default boot order

Hi,

I have a Raspberry Pi 4 with the latest firmware and I’m booting with an SSD through USB. However the booting time is really long and I get these two lines:

vc_vchi_sm_init: failed to open VCH service (-1)
vc_sm_connected_initil: failed to initialize shared memory service

Why does it take so long to boot through SSD? Is there any way I can speed it up?

Thank you

Hi,

many thanks for your message. You could ignore these 2 lines. There have nothing to do with the long boot time. Once your system is booted up, you could run following to check timings during boot.

systemd-analyze blame

Thanks for the swift response.
After reboot I got:

[FAILED] DietPi-Login | Failed to load DietPi-Globals. Skipping DietPi login scripts…

after running systemd-analyze blame:

2min 37s dev-sda2.device
1min 6s console-setup.service
36s networking.service
35s systemd-tmpfiles-setup.service.

the remaining are in ms

uhh wow 2.5 minutes to mount SDA2 drive. There seems to be something relay slow

Yeah, I that it is slow…

I googled a bit more and found that others have reported similar issues with the USB to SATA adapter
https://github.com/raspberrypi/linux/issues/3070


Bus 002 Device 002: ID 152d:0578 JMicron Technology Corp. / JMicron USA Technology Corp. JMS567 SATA 6Gb/s bridge
Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 002: ID 2109:3431 VIA Labs, Inc. Hub

I guess I have to look for another one but not sure how to know which would be compatible.

Thanks again for the help, Joulinar!

to bad, sorry that I’m not able to help. Maybe you can google the adaptors you have in mind and check if they are using JMicron chipset or not

Hi, just wanted to report that the SATA to USB adapter was the issue.
I got a new SSD case which solved the problem. Thanks for the help
https://www.amazon.de/-/en/gp/product/B07D2BHVBD/ref=ppx_yo_dt_b_asin_title_o00_s01?ie=UTF8&psc=1

Hi! I hoped I can re-use this thread for my question, also regarding the boot order of services.

I use influxdb (installed by dietpi-software) and telegraf (installed manually). DietPi is up to date (8.13.2).

But when powering on or rebooting my rPi, telegraf is always started before influxdb:

root@DietPi:~# systemd-analyze blame
13.302s influxdb.service
 2.883s ifupdown-pre.service
 2.384s php7.4-fpm.service
 1.326s unbound.service
 1.071s lighttpd.service
 1.053s ssh.service
  994ms dev-mmcblk0p2.device
  821ms dietpi-ramlog.service
  610ms telegraf.service
  547ms keyboard-setup.service
  480ms systemd-fsck@dev-disk-by\x2dpartuuid-9bcc366d\x2d01.service
  455ms systemd-udev-trigger.service
  300ms systemd-timesyncd.service
  287ms systemd-fsck-root.service
  279ms dietpi-preboot.service
  247ms systemd-journald.service
  206ms ifup@eth0.service
  ...

This leads to telegram throwing errors in the system log. Restarting telegraf on the command line (systemctl restart telegraf) instantly helps and everythings works fine.

So, how can I make telegraf wait for influxdb at booting?

you can add a condition to telegraf service to wait on influxDB service.

1 Like

Oh, cool. :slight_smile: Trying to figure it out … will come back in case I fail.

Thank you very much for the hint. I found it out.

Two simple lines do the job:

After=influxdb.service
Requires=influxdb.service