[systemd-devel] Ensuring that a unit starts before any networking
Mark Rogers
mark at more-solutions.co.uk
Sat Jun 27 11:09:29 UTC 2020
On Sat, 27 Jun 2020 at 11:51, Dave Howorth <systemd at howorth.org.uk> wrote:
> A Pi doesn't normally have an RTC, so the mixup usually takes place
> when the time is updated via NTP I believe. Do you have an RTC?
Yes I do have an RTC. At that point in the logs dhcpcd hasn't started
so it must be from the RTC (although nothing seems to appear in the
logs from a quick glance). But I only mentioned it in passing because
otherwise it looked like the logs were from different dates despite
being from the same boot.
> > also note my db2config script doesn't run until after hostname is set
> > which I would assume is set by the network startup?)
>
> Well that depends how you've set the Pi up, so you tell us, don't
> assume. If your script doesn't start until hostname is set and hostname
> is set by dhcp then you have a fundamental problem.
My script doesn't care about hostname. Hostname is set in
/etc/hostname but I don't know when that is read (nor care unless it's
a clue to why the script is running after networking starts despite my
efforts!
--
Mark Rogers
More information about the systemd-devel
mailing list