When using FEATURE(virtusertable), sendmail will do translation based on the entire domain name when the address is first read. This is similar, but not identical, to aliasing. It is commonly used to host multiple domains with different (and possibly even overlapping) users on one machine using MX records. The format of the input file (e.g., /etc/virtusertable) is:
For example, an input file might read:
firstname.lastname@example.org foo-info email@example.com bar-info firstname.lastname@example.org jdoe email@example.com firstname.lastname@example.org @bar.com mary
The first two entries translate email@example.com and firstname.lastname@example.org into different names, which may be user names or aliases. The third and fourth entries alias users to other names. The fifth entry says that email@example.com that wasn't otherwise recognized should go to mary.
You build the database from the input file using the makemap(1) program:
You declare the database for use with your .mc file, like this: