The -b flag (which stands for "become") tells sendmail which major operating mode it should run in, as follows:
| Flag | Description |
|---|---|
| -bd | This is for "become daemon". sendmail will background itself and listen for incoming SMTP connections from the network. |
| -bi | This tells sendmail to initialize its aliases database. This is assumed when sendmail is invoked as newaliases. |
| -bp | Print out the mail queue, just like the mailq command. |
| -bs | Run an SMTP session on stdout and stdin, just as if you'd telnetted to port 25. |
| -bv | Verify address mode. This flag should be followed with a list of addresses to verify. |
Here are some other commonly useful sendmail flags:
| Flag | Description |
|---|---|
| -dX | Set debugging value to X (not discussed here). |
| -Fname_of_sender | Set full name of sender to name_of_sender. Modern versions of sendmail will stamp a warning header on the outgoing message when this option is used, because it can be used to forge email. |
| -qinterval | Process the mail queue. If no interval is given, the queue will be processed only once, immediately (just like the runq command). The interval is a number with a unit tag (s for seconds, m for minutes, h for hours, d for days, w for weeks). For example, -q90m and -q1h30m both tell sendmail to process the queue every hour and a half. A typical value for this is 20 to 30 minutes. |
| -t | Tells sendmail to get the recipient of the message from the message headers. This is often used by MUAs which call sendmail to deliver outgoing mail so that they do not need to pass the recipient addresses on the commandline. |
| -v | Be verbose about alias expansions and other things. |