Mail Administration Guide

Troubleshooting Tips

This section provides some tips and tools that you can use for troubleshooting problems with the mail services.

How to Check Aliases

To verify aliases and whether mail can be delivered to a given recipient:

    Type /usr/lib/sendmail -v -bv recipient and press Return.

The command displays the aliases and identifies the final address as deliverable or not.

Here is an example of the output:


% /usr/lib/sendmail -v -bv shamira@raks
shamira... aliased to   mwong
mwong... aliased to              shamira@raks
shamira@raks... deliverable
%

You should take extra care to avoid loops and inconsistent databases when both local and domain-wide aliases are used. Be especially careful when you move a user from one system to another to avoid creating alias loops.

How to Test the sendmail Rule Sets

  1. Type /usr/lib/sendmail -bt and press Return.

    Information is displayed.

  2. At the last prompt (>) type a 3,0 (zero) and the mail address you want to test.

  3. Type Control-d to end the session.

Here is an example of the output:


% /usr/lib/sendmail -bt
ADDRESS TEST MODE (ruleset 3 NOT automatically invoked)
Enter <ruleset> <address>
> 3,0 shimara@raks
rewrite: ruleset  3   input: shimara @ raks
rewrite: ruleset  6   input: shimara <@ raks>
rewrite: ruleset  6 returns: shimara <@ raks>
rewrite: ruleset  3 returns: shimara <@ raks>
rewrite: ruleset  0   input: shimara <@ raks>
rewrite: ruleset  9   input: shimara <@ raks>
rewrite: ruleset  9 returns: shimara <@ raks>
rewrite: ruleset  0 returns: $# ether $# mailhost $: shimara < @ raks >
>

See Chapter 3, Customizing sendmail Configuration Files, for a complete description of the diagnostic information.

How to Verify Connections to Other Systems

To verify connections to other systems, you can use the mconnect program to open connections to other sendmail systems over the network. The mconnect program runs interactively. You can issue various diagnostic commands. See the mconnect(1) man page for a complete description. The following example verifies that mail to the user name shamira is deliverable.


$ mconnect raks
connecting to host raks (129.144.52.96), port 25
connection open
220 raks.Eng.Sun.COM Sendmail SMI-8.6/SMI-SVR4 ready at Tue, 25 Jul 1995 10:45:28 -0700
vrfy shamira
250 Michael Wong <shamira@raks.Eng.Sun.COM>
>

If you cannot use mconnect to connect to an SMTP port, check these conditions:

Other Diagnostic Information

For other diagnostic information, check the following sources: