Re: [systemd-devel] early mounts in systemd

2021-05-03 Thread Lennart Poettering
On Fr, 30.04.21 15:14, Kenneth Porter (sh...@sewingwitch.com) wrote: > --On Friday, April 30, 2021 11:39 AM -0400 Rick Winscot > wrote: > > > Early in the project it was decided to make the rootfs read-only... in an > > effort to improve durability in environments where power fluctuations > > mig

Re: [systemd-devel] early mounts in systemd

2021-05-03 Thread Lennart Poettering
On Fr, 30.04.21 18:23, Silvio Knizek (killermoe...@gmx.net) wrote: > Am Freitag, dem 30.04.2021 um 10:39 -0400 schrieb Rick Winscot: > > My question for anyone on the list, is the method outlined below a > > reasonable solution to mounting /var early in the start-up cycle? > > > > Or... is there a

Re: [systemd-devel] early mounts in systemd

2021-05-03 Thread Norbert Lange
I believe you can have a hard time if you dont do (the last step atleast) with a var.mount file. The mount files are special as systemd will pull those up implicitly if they are needed. Maybe you could rework your solution, so that one service mounts your first or second choice in a separate direc

Re: [systemd-devel] early mounts in systemd

2021-05-02 Thread Rick Winscot
Luca, I have a similar setup where /var/log is not mounted in initramfs for $reasons. I can’t believe I forgot to mention this! Overriding with the tips you all have mentioned have things on the right track! Many thanks to the gurus of systemd! On Sat, May 1, 2021 at 2:44 AM Luca Boccassi wro

Re: [systemd-devel] early mounts in systemd

2021-05-01 Thread Dave Howorth
On Sat, 1 May 2021 18:08:55 +0200 Michael Biebl wrote: > Am Sa., 1. Mai 2021 um 18:07 Uhr schrieb Michael Biebl > : > > > > Am Sa., 1. Mai 2021 um 17:46 Uhr schrieb Dave Howorth > > : > > > If systemd removes (i.e. doesn't obey) a directive, I'd expect it > > > to be polite and log that fact som

Re: [systemd-devel] early mounts in systemd

2021-05-01 Thread Michael Biebl
Am Sa., 1. Mai 2021 um 18:07 Uhr schrieb Michael Biebl : > > Am Sa., 1. Mai 2021 um 17:46 Uhr schrieb Dave Howorth > : > > If systemd removes (i.e. doesn't obey) a directive, I'd expect it to be > > polite and log that fact somewhere. No? > > It should, yes. To be precise, it should log a message

Re: [systemd-devel] early mounts in systemd

2021-05-01 Thread Michael Biebl
Am Sa., 1. Mai 2021 um 17:46 Uhr schrieb Dave Howorth : > If systemd removes (i.e. doesn't obey) a directive, I'd expect it to be > polite and log that fact somewhere. No? It should, yes. ___ systemd-devel mailing list systemd-devel@lists.freedesktop.org

Re: [systemd-devel] early mounts in systemd

2021-05-01 Thread Dave Howorth
On Fri, 30 Apr 2021 22:08:17 +0200 Michael Biebl wrote: > Am Fr., 30. Apr. 2021 um 20:27 Uhr schrieb Rick Winscot > : > > > At this point, flush is attempting to re-route /run/log/journal > > to /var/log/journal ... and the /var partition is not yet mounted. > > Units generated for fstab in /run/

Re: [systemd-devel] early mounts in systemd

2021-05-01 Thread Michael Biebl
Am Sa., 1. Mai 2021 um 08:44 Uhr schrieb Luca Boccassi : > > On Fri, 30 Apr 2021 at 22:15, Michael Biebl wrote: > > > > I wonder if you have a dependency loop somewhere and systemd resolves > > this by removing that ordering. > > As mentioned earlier, I strongly suspect systemd-tmpfiles-setup.serv

Re: [systemd-devel] early mounts in systemd

2021-04-30 Thread Luca Boccassi
On Fri, 30 Apr 2021 at 22:15, Michael Biebl wrote: > > Am Fr., 30. Apr. 2021 um 20:27 Uhr schrieb Rick Winscot > : > > > At this point, flush is attempting to re-route /run/log/journal to /var/log/journal ... and the /var partition is not yet mounted. Units generated for fstab in /run/systemd/gene

Re: [systemd-devel] early mounts in systemd

2021-04-30 Thread Kenneth Porter
--On Friday, April 30, 2021 11:39 AM -0400 Rick Winscot wrote: Early in the project it was decided to make the rootfs read-only... in an effort to improve durability in environments where power fluctuations might cause problems on the eMMC. At the same time, making logging (e.g. /var) persiste

Re: [systemd-devel] early mounts in systemd

2021-04-30 Thread Michael Biebl
Am Fr., 30. Apr. 2021 um 20:27 Uhr schrieb Rick Winscot : > At this point, flush is attempting to re-route /run/log/journal to > /var/log/journal ... and the /var partition is not yet mounted. Units > generated for fstab in /run/systemd/generator that manage the mount have an > After=local-fs-p

Re: [systemd-devel] early mounts in systemd

2021-04-30 Thread Rick Winscot
15:31:18 localhost systemd[1]: Dependency failed for Flush Journal to Persistent Storage. ░░ Subject: A start job for unit systemd-journal-flush.service has failed ░░ Defined-By: systemd ░░ Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel ░░ ░░ A start job for unit systemd-jour

Re: [systemd-devel] early mounts in systemd

2021-04-30 Thread Michael Biebl
Am Fr., 30. Apr. 2021 um 19:42 Uhr schrieb Rick Winscot : > > systemd 247 Ok, thanks > /etc/systemd/journald.conf storage is persistent, > systemd-journal-flush.service has RequiresMountsFor=/var/log/journal. > > Mounting /var on a separate read-write partition handles the persistent log > requ

Re: [systemd-devel] early mounts in systemd

2021-04-30 Thread Rick Winscot
systemd 247 /etc/systemd/journald.conf storage is persistent, systemd-journal-flush.service has RequiresMountsFor=/var/log/journal. Mounting /var on a separate read-write partition handles the persistent log requirement as well as offloading other read-write operations that can no longer live on

Re: [systemd-devel] early mounts in systemd

2021-04-30 Thread Silvio Knizek
Am Freitag, dem 30.04.2021 um 10:39 -0400 schrieb Rick Winscot: > My question for anyone on the list, is the method outlined below a > reasonable solution to mounting /var early in the start-up cycle? > > Or... is there a better way? Some trimming > Hi Rick, by definition if you need to mount /va

Re: [systemd-devel] early mounts in systemd

2021-04-30 Thread Luca Boccassi
On Fri, 30 Apr 2021 at 16:45, Rick Winscot wrote: > > We have an embedded product that uses a minimal Linux distribution generated via Buildroot. > > Early in the project it was decided to make the rootfs read-only... in an effort to improve durability in environments where power fluctuations migh

Re: [systemd-devel] early mounts in systemd

2021-04-30 Thread Michael Biebl
What is the actual problem you have with a separate /var and systemd-journald? For completeness sake, which systemd version do you have? Am Fr., 30. Apr. 2021 um 16:39 Uhr schrieb Rick Winscot : > > We have an embedded product that uses a minimal Linux distribution generated > via Buildroot. > >

[systemd-devel] early mounts in systemd

2021-04-30 Thread Rick Winscot
We have an embedded product that uses a minimal Linux distribution generated via Buildroot. Early in the project it was decided to make the rootfs read-only... in an effort to improve durability in environments where power fluctuations might cause problems on the eMMC. At the same time, making log