Opened 5 years ago

Closed 5 years ago

#9285 closed enhancement (fixed)

Add rpcsvc-compat and libnsl

Reported by: ken@… Owned by: DJ Lucas
Priority: normal Milestone: 8.1
Component: BOOK Version: SVN
Severity: normal Keywords:
Cc:

Description

It looks as if the removal of old rpc from glibc might now be possible. There is a release of libnss_compat at https://github.com/thkukuk/libnss_compat/releases - should work with ipv6, the old glibc (sun) code is ipv4 only.

This needs to be tested both for client and server, as well as reviewing if it can be cleanly installed over the old stuff from glibc. AFAICS no distros (except possibly OpenSuse) are using it at the moment, probably because it has not been well publicised (I saw that the old NIS code in glibc is now separated out, found a link to the proposal, and from that a pointer to the revised nis lib by the same SuSe developer, then I found this on his github page).

Not urgent, but if it works then we can drop the old rpc stuff from glibc.

Change History (8)

comment:1 by bdubbs@…, 5 years ago

Owner: changed from blfs-book@… to bdubbs@…
Status: newassigned

comment:2 by ken@…, 5 years ago

Unless I'm missing something obvious, this doesn't seem to install ANY headers. That makes me doubt it will allow rpcbind or libtirpc to build if glibc has not been told to install the old rpc. If I'm right, that will make it rather pointless.

I'll start a test build soon (I will need a perl-5.26 system to test biber once tl2017 is out).

comment:3 by bdubbs@…, 5 years ago

Owner: changed from bdubbs@… to blfs-book@…
Status: assignednew

Returning this to the book for now.

comment:4 by ken@…, 5 years ago

Milestone: 8.1y-hold

This is not yet ready for BLFS - too many development versions.

libnss_compat needs libnsl, also from [​https://github.com/thkukuk/] - and that needs a development version of libtirpc.

For the stuff I usually do (i.e. nfs2,3, not NIS nor NIS+, not nfs4 with kerberos) the following works:

libtirpc from http://git.linux-nfs.org/?p=steved/libtirpc.git (I'm not sure if that is the main upstream) - includes the rpcbomb fix, has a copy of the nis.h header, but has a typo which causes libnsl to fail to compile. Patch found at https://sourceforge.net/p/libtirpc/discussion/637321/thread/fd73d431/ - it has not yet been applied to that git tree, can be achieved with

sed -i 's/key_secret_is_set/key_secretkey_is_set/' src/libtirpc.map

This also needs "./bootstrap" (I did that before the sed) and then it can be configured as normal.

Both libnsl and libnss_compat have doubled names in the releases, use 1.0.5 and 1.2. For both of these, use

./autogen.sh
./configure --prefix=/usr--sysconfdir=/etc --disable-static
etc

rpcbind can then be built as normal.

Moving to hold until a suitable version of libtirpc has been released.

comment:5 by Armin K, 5 years ago

I have built a brand new system using glibc 2.26 git snapshot, while omitting both --enable-obsolete-rpc and --enable-obsolete-nls. I have then installed, in following order:

rpcsvc-proto
libtirpc
libnsl
libnss_compat

rpcsvc-proto, libnsl and libnss_compat are, as expected, from https://github.com/thkukuk/

So far, only package that needed fixing for rpc removal was samba, and that was to force linking to libtirpc. This did require me to add autoconf, automake and libtool to /tools, build full gettext in chapter 5 to get gettext.m4 and autopoint, and move pkg-config right after glibc in chapter 6 for autoreconf to work for these packages. I suppose proper tarballs can be generated with "make dist" and hosted on anduin, or the maintainer could be asked to do something similar on github.

https://github.com/elkrejzi/pacman/blob/master/pkgbuild/rpcsvc-proto/PKGBUILD

https://github.com/elkrejzi/pacman/blob/master/pkgbuild/libtirpc/PKGBUILD

https://github.com/elkrejzi/pacman/blob/master/pkgbuild/libnsl/PKGBUILD

https://github.com/elkrejzi/pacman/blob/master/pkgbuild/libnss_compat/PKGBUILD

Also, even though I did not use --enable-obsolete-nls, I had to manually remove /usr/lib/libnsl.so provided by glibc, so it would not conflict with one from libnsl. Both have incompatible sonames (glibc has libnsl.so.1, libnsl has libnsl.so.2, so that's fine)

Last edited 5 years ago by Armin K (previous) (diff)

comment:6 by DJ Lucas, 5 years ago

Milestone: y-hold8.1
Owner: changed from blfs-book@… to DJ Lucas
Status: newassigned

Still need yp*.h headers for at least postfix. Targeting for 8.1. This will make libnsl an optional dependency for nfs-utils.

comment:7 by DJ Lucas, 5 years ago

Summary: libnss_compatAdd rpcsvc-compat and libnsl

comment:8 by DJ Lucas, 5 years ago

Resolution: fixed
Status: assignedclosed

Fixed in r19080. The need for libnsl in postfix is specific to one of the optional deps (as it was already tagged...I believe OpenLDAP, but have not verified exactly which). I did not add libnss_compat (or friends required for NIS clients) to nfs-utils page. I started to do so, then thought better of it as it's not directly related to nfs-utils (of course the NIS client setup it isn't really complete, but that BBLFS). I don't have NIS (and haven't set one up in probably 15 years or better) so am unable to test. Feel free to uncomment if anyone thinks it deserves a mention (or add if I'm missing something).

Note: See TracTickets for help on using tickets.