Details
- Reviewers
glebius rmacklem - Commits
- rG79d0f4474653: rpcbind: Ensure krpc is present.
Diff Detail
- Repository
- rG FreeBSD src repository
- Lint
Lint Not Applicable - Unit
Tests Not Applicable
Event Timeline
I added Rick, since the change seems to me orthogonal to changes I did in CURRENT. IMHO, change is correct and is also applicable to stable/14, which doesn't have my changes.
It's the other way around; rpcbind isn't useful without krpc, and while krpc usually ends up getting loaded sooner or later, if it's not present when rpcbind starts, you get error messages on the console.
Not really useful is not really correct. It so happens that, at this time, NFS and related things
are all that is using SunRPC. However, it is easy to write a userspace only RPC apprlication.
(There are the libc library calls and rpcgen, etc.)
Saying it isn't useful without the krpc is kinda like saying "cc" isn't useful without /usr/src.
then either fix rpcbind so it doesn't print an error when started before krpc is loaded, or approve this review... your choice
Well, since I did not do the commit that broke it, I'm not sure I
should be the one fixing it.
It does appear that the glebius@ patch that adds use of netlink requires krpc.
It is not obvious to me if that means all other uses of netlink require krpc as well now.
--> If the answer is "yes", then the netlink module should get a
MODULE_DEPENDS(netlink, krpc, 1, 1, 1) added.
--> If the answer is no, then rpcbind does need to load the krpc. I'd rather see a
patch that does something like:
if (modfind("nfsd") < 0) { /* Not present in kernel, try loading it */ if (kldload("nfsd") < 0 || modfind("nfsd") < 0) errx(1, "NFS server is not available");
}
so that rpcbind will load it even when started from command line instead
of via the rc scripts.
Netlink of course doesn't need krpc, it is the opposite. Autoloading by rpcbind(8) itself seems even better.