Closed hnez closed 1 year ago
An alternative to this could also be to stay with the default poky fstab
and deploying a srv.mount
unit.
A drawback both options is that the PARTUUID
we match on is searched on all block devices, which could in theory lead to confusion with removable media.
systemd-gpt-auto-generator
is smart enough to only consider partitions on the same device as our other system partitions.
Another option is to have a look at running systemd-gpt-auto-generator
again after systemd-repart
. I don't know how frowned upon that would be.
What happens if you run systemctl daemon-reload
after systemd-repart
? It should create the mount unit, but I'm not sure if it will be mounted immediately.
PR #42 is a cleaner attempt to solve the same issue. I will close this PR.
We have previously relied on
systemd-gpt-auto-generator
to automatically generate asrv.mount
unit based on the partition type of the data partiton. The data partition is created on first boot bysystemd-repart
.This results in
/srv
not being mounted on first boot assystemd-generators
run very early in the boot process, long beforesystemd-repart
had a chance to create the partition.Add a
fstab
(mostly the defaultfstab
from poky) that includes an explicit/srv
mount.