Portmapper maps RPC (Remote Procedure Call) program numbers to IP port numbers. For instance, when a server is running NFS it registers a port with the local portmap process. When a client wants to, for instance, use NFS to mount a filesystem, the client starts by asking the portmap on the server for the port number of nfsd. The port number returned is then used by the client to contact the nfsd directly. Portmap usually defaults to listen on TCP/UDP port 111.

So if a client wants to contact nfsd on a server, it would send a request to the portmap service on that server (to port 111), requesting the port number of "program 100003". That "program number" is mapped by the portmapper to the nfsd (rpc.nfsd) process that has registered with it for TCP/UDP port number 2049 (again, thats usually the default I think). Now the client can send requests directly to TCP/UDP port 2049.

The basic thing to understand is that portmap is used to map from RPC "program numbers" to TCP/IP ports. So instead of "well known" port numbers, RPC uses well known program numbers.

Thats my basic, simplified, reasonably accurate explanation. If your looking for info you want to look for NFS and RPC. That should get you a good deal of info.