From owner-freebsd-hackers Sat May 3 10:15:02 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.5/8.8.5) id KAA05477 for hackers-outgoing; Sat, 3 May 1997 10:15:02 -0700 (PDT) Received: from skynet.ctr.columbia.edu (skynet.ctr.columbia.edu [128.59.64.70]) by hub.freebsd.org (8.8.5/8.8.5) with SMTP id KAA05465 for ; Sat, 3 May 1997 10:14:57 -0700 (PDT) Received: (from wpaul@localhost) by skynet.ctr.columbia.edu (8.6.12/8.6.9) id NAA01555; Sat, 3 May 1997 13:14:52 -0400 From: Bill Paul Message-Id: <199705031714.NAA01555@skynet.ctr.columbia.edu> Subject: Re: NIS and /etc/rpc To: chuck@fang.cs.sunyit.edu (Charles Green) Date: Sat, 3 May 1997 13:14:50 -0400 (EDT) Cc: hackers@freebsd.org In-Reply-To: <199705021916.PAA16079@fang.cs.sunyit.edu> from "Charles Green" at May 2, 97 03:16:37 pm X-Mailer: ELM [version 2.4 PL24] Content-Type: text Sender: owner-hackers@freebsd.org X-Loop: FreeBSD.org Precedence: bulk Of all the gin joints in all the towns in all the world, Charles Green had to walk into mine and say: > I was playing around with adding CDE to a freebsd 2.2.1 system running > as a nis client and I noticed that none of the rpc services that the CDE > installation added to /etc/rpc were being recognized by the system. (inetd was > reporting that csmd and ttdbserver were unknown RPC services). As it turns out > the only way I could get them recognized was by adding them to the nis server. > Shouldn't a nis client system access both the local and the nis rpc services? > > > -- > Charles Green, PRC Inc. > Rome Laboratory, NY > It should, but the code is slightly broken. getrpcent tries to do a yp_match() on the NIS maps, but it only falls back to the local /etc/rpc file if gets a YPERR_NOMAP error (i.e. map doesn't exist on server). For everything else, it just bails out. At the very least it should also roll over to the local file on a YPERR_NOKEY error as well (no such key in map), and probably YPERR_DOMAIN too (can't bind to server which serves this domain). This brings me to something I've been contamplating for a while: I'm still moving along on NIS+ (I've started on the client side now), but once it's finished, we'll need a way to integate it with libc such that system administrators can chose between NIS, NIS+, local files, DNS or whatever. Modifying libc/net to use NIS+ via the /etc/host.conf file is fine, but that doesn't help the rest of the library (getpwent, gegrent, getnetgrent, etc...). Sun of course has their name service switch for this, and Linux has its own name service switch implementation. I'm open to suggestions as to what we should use for FreeBSD. I took a look at the BIND v8 software a while back and noticed that it seems to have a sort of name service switch of its own. Is there a chance that we may adopt this, or will we have to roll our own? And if we do have to roll our own, would anyone like to volunteer to do it? :) -Bill -- ============================================================================= -Bill Paul (212) 854-6020 | System Manager, Master of Unix-Fu Work: wpaul@ctr.columbia.edu | Center for Telecommunications Research Home: wpaul@skynet.ctr.columbia.edu | Columbia University, New York City ============================================================================= "It is not I who am crazy; it is I who am mad!" - Ren Hoek, "Space Madness" =============================================================================