1

What determines when a device is announced via udev?

I have a Debian 9 squashfs-based Linux installation with which I'd like to symlink certain files in /etc to a separate, writable partition.

The problem is that my device is announced too late in the boot process (a "long" time after things like systemd-tmpfiles-setup.target, etc).

I have tried various different systemd settings (RequiredBy, etc) to have my device appear earlier, but none of the things I have tried seem to make a difference. I have tried with an entry in /etc/fstab as well as a custom systemd mount unit. No matter what I try the device always seems to be found around the same time:

Apr 17 17:49:36 host systemd[1]: Starting Flush Journal to Persistent Storage...
Apr 17 17:49:36 host systemd[1]: Started Flush Journal to Persistent Storage.
Apr 17 17:49:36 host systemd[1]: Found device ADATA_SU800NS38 os_mount.

-- Subject: Unit dev-disk-by\x2dlabel-os_mount.device has finished start-up
-- Unit dev-disk-by\x2dlabel-os_mount.device has finished starting up.
Apr 17 17:49:36 host systemd[1]: Mounting Mount Storage Partition...
-- Subject: Unit storage.mount has begun start-up

-- Unit storage.mount has begun starting up.
Apr 17 17:49:36 host systemd[1]: Mounted Mount Storage Partition.
-- Subject: Unit storage.mount has finished start-up
-- Unit storage.mount has finished starting up.

By the time the 'Found device...' line comes up, a lot of things that depend on contents of os_mount have already started (and failed).

I had this working in Debian 8, but obviously there have been a lot of changes to systemd and the boot process between Debian 8 and 9.

Thanks!

Gregoroni
  • 11
  • 1
  • While I still would like to know the answer to the question, I found this answer to solve the problem I was having: https://stackoverflow.com/a/23414312 – Gregoroni Apr 18 '18 at 20:32

0 Answers0