Name

SPT_TYPE

Synopsis

Whenever a program first begins to run, Unix provides it with two arrays of information: its command-line arguments, and the environment under which it was run. When you run ps(1) to see what processes are doing, ps prints the command line that was used to run each program.

To provide more useful information (such as current status or host connected to), sendmail saves its command line and environment, then periodically uses that system space to display its status. This ability provides a valuable tool for monitoring what each invocation of sendmail is doing.

The method to display this information is correctly defined in sendmail/conf.c (include/sm/conf.h with V8.12 and above) for all supported systems. In the rare event that you need to port sendmail to another system, you can do so by defining SPT_TYPE in sendmail/conf.h. The values that can be assigned to this SPT_TYPE are listed in Table 3-13.

Table 3-13. Values available for use with SPT_TYPE

Define

Description

SPT_BUILTIN

The system library has setproctitle(2).

SPT_CHANGEARGV

Write pointers to our own strings into the existing argv vector.

SPT_NONE

Don’t try to set the process title at all.

SPT_PSSTRINGS

Use the magic PS_STRINGS pointer (4.4BSD).

SPT_PSTAT

Use the PSTAT_SETCMD option to pstat(2).

SPT_REUSEARGV

Replace your argv with the information.

SPT_SCO

Write to the kernel’s u. area.

SPT_SYSMIPS

Use sysmips(2) supported by NEWS-OS 6.

If you set SPT_TYPE to SPT_REUSEARGV, you will ...

Get Sendmail, 3rd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.