Sendmail: Theory and Practice, Second Edition

9.4. Testing Configurations

9.4. Testing Configurations

The rules and rulesets of sendmail.cf constitute a programming language, which means that a sendmail.cf file can be considered a program. Programs even programs in use and generally considered to "work" often have bugs. Bugs tend to creep in whenever a program is changed in some way; in particular, fixing one bug often has the side effect of creating others. The sendmail.cf file makes it very easy to add bugs, since almost every complex thing a programmer wants to do has to be done indirectly and using clever side effects.

Sendmail includes a limited debugging environment for sendmail.cf files. By "limited" we mean that there is no way to change the value of macros or classes while inside the debugger; to do this, you must exit the debugger, edit the sendmail.cf file, and restart the debugger. Likewise, while tracing the execution of the sendmail.cf file, you can't change the level of granularity of the trace output without exiting the debugger and restarting it with a different command line option. There are no breakpoints. There is no way to examine the value of a macro or class. Even with these limitations, the debugging environment available for sendmail.cf files is useful, and once you get the hang of it you will be able find bugs, fix them, and test your fixes.

9.4.1. Sendmail -C

The -C command line option tells Sendmail to use some configuration file other than its...

UNLIMITED FREE
ACCESS
TO THE WORLD'S BEST IDEAS

SUBMIT
Already a GlobalSpec user? Log in.

This is embarrasing...

An error occurred while processing the form. Please try again in a few minutes.

Customize Your GlobalSpec Experience

Category: Microprocessor and IC Programmers, Compilers, and Debuggers
Finish!
Privacy Policy

This is embarrasing...

An error occurred while processing the form. Please try again in a few minutes.