* [Buildroot] [PATCH] package/php: select SYSTEMD_TMPFILES for PHP_SAPI_FPM @ 2019-11-22 9:39 Pascal de Bruijn 2019-11-25 21:10 ` Thomas Petazzoni 0 siblings, 1 reply; 5+ messages in thread From: Pascal de Bruijn @ 2019-11-22 9:39 UTC (permalink / raw) To: buildroot PrivateTmp=true requires SYSTEMD_TMPFILES otherwise the service will fail to start on boot. Signed-off-by: Pascal de Bruijn <p.debruijn@unilogic.nl> --- package/php/Config.in | 1 + 1 file changed, 1 insertion(+) diff --git a/package/php/Config.in b/package/php/Config.in index 2469573..b65438a 100644 --- a/package/php/Config.in +++ b/package/php/Config.in @@ -39,6 +39,7 @@ config BR2_PACKAGE_PHP_SAPI_CLI config BR2_PACKAGE_PHP_SAPI_FPM bool "FPM interface" + select BR2_PACKAGE_SYSTEMD_TMPFILES if BR2_PACKAGE_SYSTEMD depends on BR2_USE_MMU # "Sparc v8 and predecessors are not and will not be supported" depends on !BR2_sparc -- 2.7.4 ^ permalink raw reply related [flat|nested] 5+ messages in thread
* [Buildroot] [PATCH] package/php: select SYSTEMD_TMPFILES for PHP_SAPI_FPM 2019-11-22 9:39 [Buildroot] [PATCH] package/php: select SYSTEMD_TMPFILES for PHP_SAPI_FPM Pascal de Bruijn @ 2019-11-25 21:10 ` Thomas Petazzoni 2019-11-26 17:45 ` Jérémy ROSEN 0 siblings, 1 reply; 5+ messages in thread From: Thomas Petazzoni @ 2019-11-25 21:10 UTC (permalink / raw) To: buildroot Hello J?r?my, Do you have some feedback about this patch ? Thanks, Thomas On Fri, 22 Nov 2019 10:39:30 +0100 Pascal de Bruijn <p.debruijn@unilogic.nl> wrote: > PrivateTmp=true requires SYSTEMD_TMPFILES otherwise the service will > fail to start on boot. > > Signed-off-by: Pascal de Bruijn <p.debruijn@unilogic.nl> > --- > package/php/Config.in | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/package/php/Config.in b/package/php/Config.in > index 2469573..b65438a 100644 > --- a/package/php/Config.in > +++ b/package/php/Config.in > @@ -39,6 +39,7 @@ config BR2_PACKAGE_PHP_SAPI_CLI > > config BR2_PACKAGE_PHP_SAPI_FPM > bool "FPM interface" > + select BR2_PACKAGE_SYSTEMD_TMPFILES if BR2_PACKAGE_SYSTEMD > depends on BR2_USE_MMU > # "Sparc v8 and predecessors are not and will not be supported" > depends on !BR2_sparc -- Thomas Petazzoni, CTO, Bootlin Embedded Linux and Kernel engineering https://bootlin.com ^ permalink raw reply [flat|nested] 5+ messages in thread
* [Buildroot] [PATCH] package/php: select SYSTEMD_TMPFILES for PHP_SAPI_FPM 2019-11-25 21:10 ` Thomas Petazzoni @ 2019-11-26 17:45 ` Jérémy ROSEN 2019-12-04 8:53 ` Jérémy ROSEN 0 siblings, 1 reply; 5+ messages in thread From: Jérémy ROSEN @ 2019-11-26 17:45 UTC (permalink / raw) To: buildroot systemd-tmpfiles is a small utility provided by systemd to do "file system tweaks" early during the boot The primary use-case is to populate /run early so everything is ready when the "real stuff" starts but it can do all sort of things * create files * remove files * write to files * adjust file permissions/ACL.. * create nodes in /dev systemd-tmpfiles avoids launching dozen of small processes/subshells for small adjustment as it is don intraditionnal sysV startup files systemd-tmpfiles configuration is drop-in based so any package can add file in the proper directory to be sure things are created/adjusted at boot time. moreover systemd-tmpfiles is needed to be able to dynamically load modules : * at boot time, systemd will scan modules in /lib/modules (using modinfo) to know all /dev nodes that unloaded modules can handle * systemd-tmpfiles will create the corresponding nodes in /dev * when a process opens the node, the kernel will block the process and call udev * udev will find the module to load (using modules.alias) * once the module is loaded, the kernel will honor the open request and unblock the process. systemd-tmpfiles is not an optional part of systemd. Buildroot configures it that way, but packages are supposed to safely assume it's there on any systemd-based system So I would consider it a bug to have systemd-tmpfiles be optional. I'd rather see a patch removing that aspect entirely. Now... if we want to keep that option (which, again, I don't recommend) yes. This patch looks good to me. Le lun. 25 nov. 2019 ? 22:10, Thomas Petazzoni <thomas.petazzoni@bootlin.com> a ?crit : > Hello J?r?my, > > Do you have some feedback about this patch ? > > Thanks, > > Thomas > > On Fri, 22 Nov 2019 10:39:30 +0100 > Pascal de Bruijn <p.debruijn@unilogic.nl> wrote: > > > PrivateTmp=true requires SYSTEMD_TMPFILES otherwise the service will > > fail to start on boot. > > > > Signed-off-by: Pascal de Bruijn <p.debruijn@unilogic.nl> > > --- > > package/php/Config.in | 1 + > > 1 file changed, 1 insertion(+) > > > > diff --git a/package/php/Config.in b/package/php/Config.in > > index 2469573..b65438a 100644 > > --- a/package/php/Config.in > > +++ b/package/php/Config.in > > @@ -39,6 +39,7 @@ config BR2_PACKAGE_PHP_SAPI_CLI > > > > config BR2_PACKAGE_PHP_SAPI_FPM > > bool "FPM interface" > > + select BR2_PACKAGE_SYSTEMD_TMPFILES if BR2_PACKAGE_SYSTEMD > > depends on BR2_USE_MMU > > # "Sparc v8 and predecessors are not and will not be supported" > > depends on !BR2_sparc > > > > -- > Thomas Petazzoni, CTO, Bootlin > Embedded Linux and Kernel engineering > https://bootlin.com > -- [image: SMILE] <http://www.smile.eu/> 20 rue des Jardins 92600 Asni?res-sur-Seine *J?r?my ROSEN* Architecte technique [image: email] jeremy.rosen at smile.fr [image: phone] +33 6 88 25 87 42 [image: url] http://www.smile.eu [image: Twitter] <https://twitter.com/GroupeSmile> [image: Facebook] <https://www.facebook.com/smileopensource> [image: LinkedIn] <https://www.linkedin.com/company/smile> [image: Github] <https://github.com/Smile-SA> [image: D?couvrez l?univers Smile, rendez-vous sur smile.eu] <https://www.smile.eu/fr/publications/livres-blancs/yocto?utm_source=signature&utm_medium=email&utm_campaign=signature> -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20191126/51252cb2/attachment.html> ^ permalink raw reply [flat|nested] 5+ messages in thread
* [Buildroot] [PATCH] package/php: select SYSTEMD_TMPFILES for PHP_SAPI_FPM 2019-11-26 17:45 ` Jérémy ROSEN @ 2019-12-04 8:53 ` Jérémy ROSEN 2021-08-05 19:51 ` Thomas Petazzoni 0 siblings, 1 reply; 5+ messages in thread From: Jérémy ROSEN @ 2019-12-04 8:53 UTC (permalink / raw) To: buildroot Ok, for the special case of PHP, this has been fixed upstream with https://github.com/systemd/systemd/pull/14207 The official word from upstream is "yes tmpfiles is optional but it should always be here except for really tiny embedded systems" So we are good (tmpfile's default is activated) Ideally, we should backport that PR until upstream adds it to systemd-stable. BR J?r?my Le mar. 26 nov. 2019 ? 18:45, J?r?my ROSEN <jeremy.rosen@smile.fr> a ?crit : > systemd-tmpfiles is a small utility provided by systemd to do "file system > tweaks" early during the boot > > The primary use-case is to populate /run early so everything is ready when > the "real stuff" starts but it can do all sort of things > * create files > * remove files > * write to files > * adjust file permissions/ACL.. > * create nodes in /dev > > systemd-tmpfiles avoids launching dozen of small processes/subshells for > small adjustment as it is don intraditionnal sysV startup files > > systemd-tmpfiles configuration is drop-in based so any package can add > file in the proper directory to be sure things are created/adjusted at boot > time. > > moreover systemd-tmpfiles is needed to be able to dynamically load modules > : > * at boot time, systemd will scan modules in /lib/modules (using modinfo) > to know all /dev nodes that unloaded modules can handle > * systemd-tmpfiles will create the corresponding nodes in /dev > * when a process opens the node, the kernel will block the process and > call udev > * udev will find the module to load (using modules.alias) > * once the module is loaded, the kernel will honor the open request and > unblock the process. > > systemd-tmpfiles is not an optional part of systemd. Buildroot configures > it that way, but packages are supposed to safely assume it's there on any > systemd-based system > > So I would consider it a bug to have systemd-tmpfiles be optional. I'd > rather see a patch removing that aspect entirely. > > Now... if we want to keep that option (which, again, I don't recommend) > yes. This patch looks good to me. > > > > Le lun. 25 nov. 2019 ? 22:10, Thomas Petazzoni < > thomas.petazzoni at bootlin.com> a ?crit : > >> Hello J?r?my, >> >> Do you have some feedback about this patch ? >> >> Thanks, >> >> Thomas >> >> On Fri, 22 Nov 2019 10:39:30 +0100 >> Pascal de Bruijn <p.debruijn@unilogic.nl> wrote: >> >> > PrivateTmp=true requires SYSTEMD_TMPFILES otherwise the service will >> > fail to start on boot. >> > >> > Signed-off-by: Pascal de Bruijn <p.debruijn@unilogic.nl> >> > --- >> > package/php/Config.in | 1 + >> > 1 file changed, 1 insertion(+) >> > >> > diff --git a/package/php/Config.in b/package/php/Config.in >> > index 2469573..b65438a 100644 >> > --- a/package/php/Config.in >> > +++ b/package/php/Config.in >> > @@ -39,6 +39,7 @@ config BR2_PACKAGE_PHP_SAPI_CLI >> > >> > config BR2_PACKAGE_PHP_SAPI_FPM >> > bool "FPM interface" >> > + select BR2_PACKAGE_SYSTEMD_TMPFILES if BR2_PACKAGE_SYSTEMD >> > depends on BR2_USE_MMU >> > # "Sparc v8 and predecessors are not and will not be supported" >> > depends on !BR2_sparc >> >> >> >> -- >> Thomas Petazzoni, CTO, Bootlin >> Embedded Linux and Kernel engineering >> https://bootlin.com >> > > > -- > [image: SMILE] <http://www.smile.eu/> > > 20 rue des Jardins > 92600 Asni?res-sur-Seine > *J?r?my ROSEN* > Architecte technique > > [image: email] jeremy.rosen at smile.fr > [image: phone] +33 6 88 25 87 42 > [image: url] http://www.smile.eu > > [image: Twitter] <https://twitter.com/GroupeSmile> [image: Facebook] > <https://www.facebook.com/smileopensource> [image: LinkedIn] > <https://www.linkedin.com/company/smile> [image: Github] > <https://github.com/Smile-SA> > > [image: D?couvrez l?univers Smile, rendez-vous sur smile.eu] > <https://www.smile.eu/fr/publications/livres-blancs/yocto?utm_source=signature&utm_medium=email&utm_campaign=signature> > -- [image: SMILE] <http://www.smile.eu/> 20 rue des Jardins 92600 Asni?res-sur-Seine *J?r?my ROSEN* Architecte technique [image: email] jeremy.rosen at smile.fr [image: phone] +33 6 88 25 87 42 [image: url] http://www.smile.eu [image: Twitter] <https://twitter.com/GroupeSmile> [image: Facebook] <https://www.facebook.com/smileopensource> [image: LinkedIn] <https://www.linkedin.com/company/smile> [image: Github] <https://github.com/Smile-SA> [image: D?couvrez l?univers Smile, rendez-vous sur smile.eu] <https://www.smile.eu/fr/publications/livres-blancs/yocto?utm_source=signature&utm_medium=email&utm_campaign=signature> -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20191204/df5ab6a5/attachment-0001.html> ^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [Buildroot] [PATCH] package/php: select SYSTEMD_TMPFILES for PHP_SAPI_FPM 2019-12-04 8:53 ` Jérémy ROSEN @ 2021-08-05 19:51 ` Thomas Petazzoni 0 siblings, 0 replies; 5+ messages in thread From: Thomas Petazzoni @ 2021-08-05 19:51 UTC (permalink / raw) To: Jérémy ROSEN; +Cc: buildroot, Pascal de Bruijn Hello Jérémy, On Wed, 4 Dec 2019 09:53:53 +0100 Jérémy ROSEN <jeremy.rosen@smile.fr> wrote: > Ok, for the special case of PHP, this has been fixed upstream with > > https://github.com/systemd/systemd/pull/14207 > > The official word from upstream is "yes tmpfiles is optional but it should > always be here except for really tiny embedded systems" > > So we are good (tmpfile's default is activated) > > Ideally, we should backport that PR until upstream adds it to > systemd-stable. It's been a while ago, but if I understand correctly what you said, because PR14207 has been merged upstream, we no longer need absolutely need tmpfiles support in systemd for PHP's FPM interface to work. We're now using a much newer systemd version in Buildroot, which must have PR14207 applied. So I've marked this patch as Rejected. Pascal, if you disagree and still see a problem, do not hesitate to resubmit the patch. Thanks a lot, Thomas -- Thomas Petazzoni, co-owner and CEO, Bootlin Embedded Linux and Kernel engineering https://bootlin.com _______________________________________________ buildroot mailing list buildroot@busybox.net http://lists.busybox.net/mailman/listinfo/buildroot ^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2021-08-05 19:59 UTC | newest] Thread overview: 5+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2019-11-22 9:39 [Buildroot] [PATCH] package/php: select SYSTEMD_TMPFILES for PHP_SAPI_FPM Pascal de Bruijn 2019-11-25 21:10 ` Thomas Petazzoni 2019-11-26 17:45 ` Jérémy ROSEN 2019-12-04 8:53 ` Jérémy ROSEN 2021-08-05 19:51 ` Thomas Petazzoni
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox