FreeBSD Manual Pages
BULK_MAILER(1) General Commands Manual BULK_MAILER(1) NAME bulk_mailer - assist in delivery of mail to large numbers of recipients SYNOPSIS bulk_mailer [-comment comment] [-debug] [-domain domainname] [-list- archive text] [-list-help text] [-list-owner text] [-list-post text] [-list-unsubscribe text] [-maxdomains maxdomains] [-maxrcpts maxrcpts] [-maxsize maxsize] [-owner list-owner-address] [-precedence precedence- keyword] [-private] [-reply-to reply-address] [+reply-to reply-address] [-s] [-sendmail sendmail-flags] [-v] envelope-from recipient-list-file DESCRIPTION Bulk_mailer reads the message to be sent (with headers already at- tached) from stdin, sets envelope as the envelope return address for the mailing list, and delivers it to all recipient addresses listed one-per-line in recipient-list-file. It sorts the recipient list by reversed domain (so similar ones sort together), splits up the recipi- ents into several groups containing no more than N domains each, cre- ates an SMTP envelope for each group of recipients, and feeds that en- velope to /usr/lib/sendmail -bs. Splitting the envelopes up allows sendmail to perform delivery in par- allel, so instead of having one large queue entry (for which sendmail might take awhile to get around to attempting delivery for some recipi- ents), it has several smaller queue entries. Depending on your point- of-view, this can still be considered cluttering up your mail queue, but it does seem to deliver messages more quickly to most recipients. The core of this program was extracted from a somewhat strange mailing list manager called na-net; it was designed to efficiently send out mail to 5000 people at a time. I have used this program to attempt de- livery of a message to over 12000 recipients around the world, within a few hours. I'm currently using bulk_mailer as a back-end for several mailing lists of modest size. However, the program is not extensively tested, and may not work well in all environments. See BUGS below. Envelope_from is the envelope return address for the mailing list. This should either be the address of a human list maintainer, or the address of a robot that tries to recognize bounced mail messages and grok it, forwarding anything it doesn't understand to a human. Recipient_list_file is a filename of a list of recipients, one recipi- ent per line. Bulk_mailer's address prefrobnicator tries to understand several forms of address, e.g.: Keith Moore <moore@cs.utk.edu> moore@cs.utk.edu (Keith Moore) "Keith Moore" <"keith.moore"@cs.utk.edu> (Moore, Keith) should all do the right thing. OPTIONS -delete-list-hdrs Delete any List-* header fields that appear in the input. This option is automatically set if any of the -list-* options are set. -debug Don't actually mail the stuff. instead, spit SMTP to stdout -domain domainname Set the local domain name to domainname. If not set, bulk_mailer will try to figure out the name on its own. Note: This should be a fully-qualified domain name - not just the first component (aka the hostname). If the domain name doesn't have a '.' it's rejected. -list-archive text Add a header of the form 'List-Archive: text'. This should con- tain a URL pointing to a list archive, or a mailto: URL which, if sent a piece of mail, will return instructions to access the list archive. The URL should be surrounded by < and >. Read RFC 2369 before setting this option. -list-help text Add a header of the form 'List-Help: text'. This should contain a URL of a help file, or a mailto: URL which, if sent a piece of mail, will cause the help file to be returned. The URL should be surrounded by < and >. Read RFC 2369 before setting this op- tion. -list-owner text Add a header of the form 'List-Owner: text'. This should con- tain the mailto: URL of the list owner, surrounded by < and >. Read RFC 2369 before setting this option. -list-post text Add a header of the form 'List-Post: text'. This should contain either the word "NO", or a URL giving the posting address for the list. (Normally this will be a mailto: URL, but it might also be a web page.) Read RFC 2369 before setting this option. -list-subscribe text Add a header of the form 'List-Subscribe: text'. This should contain the URL (surrounded by < >) of a web page or mail server that can be used to subscribe to the list. Read RFC 2369 before setting this option. -list-unsubscribe text Add a header of the form 'List-Unsubscribe: text'. This should contain the URL (surrounded by < >) of a web page or mail server that can be used to unsubscribe to the list. Read RFC 2369 be- fore setting this option. -maxdomains maxdomains Set the maximum number of domains per envelope to maxdomains. If not explicitly set, 20 is the default. -maxrcpts maxrcpts Set the maximum number of recipients per envelope to maxrcpts. If not explicitly set, 100 is the default. This is used to work around a bug in RFC 821 (and in many MTAs) where a permanent er- ror code is returned when the number of recipients in an SMTP session exceeds some pre-set limit. -maxsize maxsize Reject any message larger than maxsize bytes. -owner list-owner-address Set the list owner address. If the message looks like a bounce, or if it contains [un]subscribe commands and the -s flag is set, the mail will be forwarded to this address instead of being dis- tributed to the list. -precedence precedence-keyword Add a Precedence: precdence-keyword header. Precedence-keyword should be a keyword recognized by sendmail. NOT RECOMMENDED. WARNING: some mailers will bounce the mail if they see a Prece- dence header with a keyword they don't understand; some list managers will silently drop the mail if they see a Precedence header with a keyword they do understand. There is NO safe value for the Precedence header that won't cause some mailer to mishandle the message. This option is therefore not recom- mended. -private If this flag is set, and the address in the From header field does not match the address of one of the list subscribers (or if there is no From header field), print an error message to stderr and return a EX_NOPERM exit code. If bulk_mailer was called from sendmail, this exit code will cause a nondelivery report to be returned to the author. -reply-to reply-address Add a Reply-to: reply-address header to the resent message if there wasn't one in the input. Use of the reply-to header by lists is questionable; see http://www.unicom.com/FAQ/reply-to-evil.html for some of the reasons why. +reply-to reply-address Add a Reply-to: reply-address header to the resent message, overriding any reply-to header in the input. NOT RECOMMENDED. If having a list use reply-to is questionable, overriding the sender's reply-to header is even worse. This option should be used only in very unusual cases. -s Check for "unsubscribe" or similar administrative requests in the Subject header field or the message body. If found, do not deliver the message to the list recipients but forward it to the list owner. -sendmail sendmail-flags Add sendmail-flags to the sendmail command-line. For instance, -sendmail -Odq would have bulk_mailer pass the -Odq flag to sendmail, which tells it: just queue the message, don't attempt to deliver it immediately. -v Be verbose. To have bulk_mailer distributed mail to a list, add the following lines to /etc/aliases: {FOO}-request: whoever-maintains-foo owner-{FOO}: whoever-maintains-foo {FOO}: "|{BULK_MAILER} owner-{FOO}@{YOUR.DOMAIN} {ADDRESS_LIST}" where {FOO} is the name of the list, {YOUR.DOMAIN} is your fully-quali- fied domain, {BULK_MAILER} is a full path name of the bulk_mailer pro- gram, and {ADDRESS_LIST} is a full path name of the file containing the list of addresses. DIAGNOSTICS SEE ALSO sendmail(8) G. Neufeld, J. Baer. The Use of URLs as Meta-Syntax for Core Mail List Commands and their Transport through Message Header Fields. RFC 2369, July 1998. AUTHOR Keith Moore, <moore@cs.utk.edu> BUGS If your system has per-user process quotas, or a small number of process table entries, you will want to modify this program to recover gracefully when these are exhausted. The -private flag currently has a number of shortcomings. It always bounces the message if the author is not a list subscriber (there's no provision for a moderator), the error message text is hard-coded into the program, there's no provision for a separate list of people who are allowed to post even though they are not list subscribers, and the ad- dress matching algorithm only does exact (case-insensitive) matching - it doesn't take sub-addresses, or sub-domains, into account. 4th Berkeley Distribution BULK_MAILER(1)
NAME | SYNOPSIS | DESCRIPTION | OPTIONS | DIAGNOSTICS | SEE ALSO | AUTHOR | BUGS
Want to link to this manual page? Use this URL:
<https://man.freebsd.org/cgi/man.cgi?query=bulk_mailer&sektion=1&manpath=FreeBSD+Ports+15.0>
