Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 10 Jun 2025 12:11:18 +0300
From:      Konstantin Belousov <kostikbel@gmail.com>
To:        Gleb Smirnoff <glebius@freebsd.org>
Cc:        Rick Macklem <rick.macklem@gmail.com>, Dag-Erling =?utf-8?B?U23DuHJncmF2?= <des@freebsd.org>, src-committers@freebsd.org, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org
Subject:   Re: git: 79d0f4474653 - main - rpcbind: Ensure krpc is present.
Message-ID:  <aEf2tqXgHDo8SMBb@kib.kiev.ua>
In-Reply-To: <aEegKoTN-ej0C5_Z@cell.glebi.us>
References:  <202506091053.559ArJ8k043104@gitrepo.freebsd.org> <aEbKLniIuHd4xuq7@kib.kiev.ua> <CAM5tNy7uGWg4gOsy%2BM7_vneObuszzxNhGAJF-6rd%2Byjqc00QeA@mail.gmail.com> <aEbPE5oG47SuN2y0@kib.kiev.ua> <CAM5tNy6-xtDYQPw6vr588e2r=tX76pWZnKPczwaCrZ5j5XnCEw@mail.gmail.com> <aEdJQybzSOzR3BS0@cell.glebi.us> <aEd5lozkABjyg0UZ@kib.kiev.ua> <aEegKoTN-ej0C5_Z@cell.glebi.us>

next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, Jun 09, 2025 at 08:02:02PM -0700, Gleb Smirnoff wrote:
> On Tue, Jun 10, 2025 at 03:17:26AM +0300, Konstantin Belousov wrote:
> K> > R> My vague recollection (I'll admit I cannot be bothered looking at the
> K> > R> older code)
> K> > R> is that rpcbind would accept queries on a AF_LOCAL (unix domain) socket for
> K> > R> local RPC processes.
> K> > R> 
> K> > R> glebius@ does not want RPCs to be done over AF_LOCAL sockets (he would
> K> > R> have to explain why), so he created an RPC layer in the krpc for netlink as an
> K> > R> alternative and converted all utilities that were doing RPCs over AF_LOCAL
> K> > R> sockets to use it.
> K> > 
> K> > Not exactly. I don't want kernel RPC to userland to use AF_LOCAL. A process to
> K> > a process RPC of course continues to use AF_LOCAL.
> K> > 
> K> > What would be better for rpcbind: to skip providing kernel RPC services if
> K> > krpc(4) not detected at startup, or to autoload krpc?  The latter makes it safe
> K> > for a scenario when NFS is instantiated at a later runtime of a machine, when
> K> > rpcbind already runs. The former scenario would require a restart of rpcbind.
> K> > 
> K> 
> K> IMO rpcbind must not load any modules.  It should communicate with krpc if
> K> available.
> K> 
> K> The krpc load is the global system policy decision, it should be handled
> K> in rc scripts, as it is common for such decisions.  The loading would be
> K> enabled if some component requires krpc, which means if nfsd enabled.
> K> It would be ordered before rpcbind startup, of course.
> 
> My only concern is that it would require restart of rpcbind, if sysadmin
> decides to configure NFS later after startup.

Well, yes.

Apparently we already have the feature called 'warmstart', where rpcbind
can be restarted and existing registrations are reloaded.  So it is in
fact already solved, assuming admin is careful enough to use -w.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?aEf2tqXgHDo8SMBb>