Date: Tue, 10 Jun 2025 08:57:11 -0700 From: Rick Macklem <rick.macklem@gmail.com> To: Gleb Smirnoff <glebius@freebsd.org> Cc: Konstantin Belousov <kostikbel@gmail.com>, =?UTF-8?Q?Dag=2DErling_Sm=C3=B8rgrav?= <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: <CAM5tNy73foc9hY%2B_K05nc30wrGtmqmo=V9TFfabo%2BzOPrsferA@mail.gmail.com> In-Reply-To: <aEhSOKKsHqfaFlNZ@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> <aEf2tqXgHDo8SMBb@kib.kiev.ua> <aEhSOKKsHqfaFlNZ@cell.glebi.us>
next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, Jun 10, 2025 at 8:41=E2=80=AFAM Gleb Smirnoff <glebius@freebsd.org>= wrote: > > CAUTION: This email originated from outside of the University of Guelph. = Do not click links or open attachments unless you recognize the sender and = know the content is safe. If in doubt, forward suspicious emails to IThelp@= uoguelph.ca. > > On Tue, Jun 10, 2025 at 12:11:18PM +0300, Konstantin Belousov wrote: > K> Apparently we already have the feature called 'warmstart', where rpcbi= nd > K> can be restarted and existing registrations are reloaded. So it is in > K> fact already solved, assuming admin is careful enough to use -w. > > Ok, then all that needs to be done is revert this: > > --- a/usr.sbin/rpcbind/rpcbind.c > +++ b/usr.sbin/rpcbind/rpcbind.c > @@ -159,10 +159,6 @@ main(int argc, char *argv[]) > > update_bound_sa(); > > - /* Ensure krpc is loaded */ > - if (modfind("krpc") < 0 && kldload("krpc") < 0) > - err(1, "krpc"); > - > /* Check that another rpcbind isn't already running. */ > if ((rpcbindlockfd =3D open(RPCBINDDLOCK, O_RDONLY|O_CREAT, 0444)= ) < 0) > err(1, "%s", RPCBINDDLOCK); > > Without these lines, rpcbind will log: > > Jun 10 08:34:23 bobrik rpcbind[885]: netlink: could not create service > > And continue with /var/run/rpcbind.sock set up and ready to service > requests from applications. > > We can add an extra message for verbosity: > > @@ -223,7 +219,10 @@ main(int argc, char *argv[]) > } > endnetconfig(nc_handle); > > - init_transport(&netlink_nconf); > + if (init_transport(&netlink_nconf) !=3D 0) { > + syslog(LOG_ERR, "krpc(4) module missing? " > + "Continuing without netlink/krpc transport"); > + } > > /* > * Allocate pipe fd to wake main thread from signal handler in no= n-racy > > I really don't have a strong opinion on what would be right here. I have= no > idea on how wide is the use of rpcbind w/o NFS. Kostik, Rick and Dag-Erl= ing, > may you together come to agreement on what is right here? I don't have a strong opinion on it either, since most kernel configs include NFS options, so the krpc is there anyhow. rick > > -- > Gleb Smirnoff
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAM5tNy73foc9hY%2B_K05nc30wrGtmqmo=V9TFfabo%2BzOPrsferA>