Path: utzoo!utgpu!watserv1!watmath!att!linac!uwm.edu!src.honeywell.com!msi.umn.edu!cs.umn.edu!uc!shamash!timbuk!poplar13!bstrand From: bstrand@poplar13.cray.com (Brad Strand) Newsgroups: comp.protocols.tcp-ip Subject: Re: How to find directory of rpc services? Keywords: rpc, portmapper, client, server Message-ID: <183342.17950@timbuk.cray.com> Date: 16 Feb 91 01:03:30 GMT References: <6988@bgsuvax.UUCP> Distribution: na Organization: Cray Research, Inc., Eagan, MN Lines: 24 In article <6988@bgsuvax.UUCP> rama@bgsuvax.UUCP (Sub Ramakrishnan) writes: > >Question: How does a client find the "directory" of services >(service name, port # and a description) offered on a machine. >The client knows neither the name nor the server port #. >Two ways that I don't like: >(1). The client can exhaustively poll all possible port #s. >(2) Read /etc/services file; does'nt give you services that "come & go". >I am looking for ways to find the services at run time. Use "pmap_getmaps()". It takes a pointer to a sockaddr_in structure for the remote host, and returns a pointer to a pmaplist structure. If you've got source for rpcinfo, look how that program does it. >Much appreciated. >sub ramakrishnan rama@truth.bgsu.edu Voice: 419 372 2337 BDS -- Brad Strand bstrand@cray.com (DOMAIN) uunet!cray!bstrand (UUCP) Cray Research, Inc. Networking and Communications Development 655F Lone Oak Drive #include Eagan, MN 55121 "No gnu taxes."