public inbox for libc-alpha@sourceware.org
 help / color / mirror / Atom feed
* On the removal of nscd from Fedora, and the future of nscd.
@ 2022-02-28 20:55 Carlos O'Donell
  2022-02-28 23:02 ` DJ Delorie
  0 siblings, 1 reply; 11+ messages in thread
From: Carlos O'Donell @ 2022-02-28 20:55 UTC (permalink / raw)
  To: Ludovic Courtès, Arjun Shankar, Florian Weimer,
	Adhemerval Zanella, libc-alpha, DJ Delorie

In Fedora 36 we officially removed nscd from the distribution with this
system-wide change request:
https://fedoraproject.org/wiki/Changes/RemoveNSCD

I say "we" but it was the entire Fedora glibc team, which includes various
developers also on this list like Arjun, Florin, and DJ. We took this action
because over time glibc should focus on the important parts of being a core
runtime. We felt sssd and systemd had grown to the point where they were
well supported and and supporting nscd in Fedora was no longer required.

Ludovic reached out to me regarding the removal because Guix uses nscd
for the interesting use case of supporting multiple system libcs:
https://guix.gnu.org/manual/devel/en/html_node/Application-Setup.html#Name-Service-Switch-1

The idea is very clever in that if you always make the lookup in the system
nscd then the process with the alternative libc is decoupled from the system
libc and all the system plugins required to answer the lookup request.

Ludovic and I compared notes on the future of nscd, and we discussed a what-if
scenario. What if we kept nscd, but removed all the caches, and left it as a
daemon that could answer requests from system processes but the only goal was
to decouple the libc required to service the request and the libc in the process?

This is already starting to sound like Florian's getent idea where by a static
process uses a known binary to carry out the NSS lookup and resolution [1].

What if instead of getent we just thinned down nscd to something we could audit
and trust? If we really wanted to we could even compile the same code into getent
as a fallback e.g. try nscd first (long lived) then getent (short lived).

You might say "Well then nscd is mis-named!" I'd argue it's a "cache" for the shared
objects and state required to do the lookup, but not the data itself, and if you
didn't run nscd then you'd go through NSS normally, or "getent" if you were a
statically compiled binary.

Thoughts?

-- 
Cheers,
Carlos.

[1] https://sourceware.org/legacy-ml/libc-alpha/2017-12/msg00831.html


^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2022-11-20 18:34 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-02-28 20:55 On the removal of nscd from Fedora, and the future of nscd Carlos O'Donell
2022-02-28 23:02 ` DJ Delorie
2022-02-28 23:09   ` Joseph Myers
2022-03-01  1:02     ` DJ Delorie
2022-03-01  9:10   ` Ludovic Courtès
2022-03-01 16:54     ` DJ Delorie
2022-03-01 17:44       ` Ludovic Courtès
2022-03-01 18:31         ` DJ Delorie
2022-03-03 13:40           ` Ludovic Courtès
2022-03-06 22:05             ` John Ericson
2022-11-20 18:34               ` Florian Klink

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).