Sun Microsystems offers a network information service called NIS. It provides the ability to look up various kinds of information in network databases. The nis type allows you to access that network information by way of rules in rule sets. You declare an nis database-map type like this: K name nis nismap Here, name is the identifier that you will later use in rule sets. The nismap is any NIS database map that defaults to mail.aliases . Lookups will occur in the default NIS domain. If you wish to specify some other domain, you can append an @ character and the domain name to the nismap : K name nis nismap @ domain To illustrate , consider the need to look up the name of the central mail server for your department. If such a database map were called mailservers , you could use the following configuration file line to look up your domain in that database map: Kmailservers nis -o mailservers ... R $* <@ $+ > $* $: <@> <$(mailservers $)> R $* <@ $+ > $* <$+> $#smtp $@ $: < @ > ... Here, we look up the host part of an address ( $2 ) in the mailservers NIS database map. The -o makes the existence of the database map optional. If the host part is found, it is rewritten to be the name of the mail server for that host. In the last rule we forward the original address to that server. Without the -o , the nonexistence of a database map will cause this error to be logged: Cannot bind to map name in domain domain : reason here If NIS is not running or if sendmail cannot bind to the domain specified for the default domain, the following error is logged: 421 4.3.5 NIS map name specified, but NIS not running Only a few database switches are available with this nis database-map type. They can be found in Table 23-19. Table 23-19. The nis database-map type K command switches
The nis database-map type is available only if sendmail is compiled with NIS defined (NIS). |