]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core.git/commit
rpcbind: Fix boot time start failure
authorZoltan Boszormenyi <zboszor@gmail.com>
Sun, 28 Jul 2024 14:29:06 +0000 (16:29 +0200)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Sat, 3 Aug 2024 06:55:32 +0000 (07:55 +0100)
commit53fb871f84c99a66485979da2588c1d11d8749e7
tree85ab258b80de8b4d3c31d04ca1bc98f345a86c3d
parente2030c0d747eb990b9ad10098c6b74d6f8f4e74e
rpcbind: Fix boot time start failure

With commits 90bc1810 ("bitbake.conf: Add runtimedir") and
561e853e ("rpcbind: Specify state directory under /run") rpcbind
still can fail during startup with:

  rpcbind: /var/run/rpcbind.lock: Read-only file system

The lockfile is hardcoded as "/var/run/rpcbind.lock".
While it should use the same internal define "RPCBIND_STATEDIR"
as the paths for rpcbind.xdr and portmap.xdr, it's not necessary
to be patched because of the default value of ${runtimedir} and
the presence of the /var/run -> /run symlink.

Using --with-statedir=/run/rpcbind adds the line

  RequiresMountsFor=/run/rpcbind

to the service but it doesn't guarantee that /run is writable yet
when rpcbind.service starts. Add this guarantee by running
rpcbind.service with systemd-tmpfiles-setup.service and add the
tmpfiles.d entry for /run/rpcbind.

Signed-off-by: Zoltán Böszörményi <zboszor@gmail.com>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/recipes-extended/rpcbind/rpcbind/rpcbind.systemd [new file with mode: 0644]
meta/recipes-extended/rpcbind/rpcbind/rpcbind.tmpfiles [new file with mode: 0644]
meta/recipes-extended/rpcbind/rpcbind_1.2.6.bb