From 8d4f8c5d807f1b1a9b75eecaab83895d36f4f40a Mon Sep 17 00:00:00 2001
From: Wietse Venema NOTE: By default, address verification information is not stored
-in a persistent file. You have to specify one in main.cf (see
-below). Persistent storage is off by default because it may need
-more disk space than is available in your file system. Address verification information is cached by the Postfix verify
-daemon. Postfix has a bunch of parameters that control the caching
-of positive and negative results. Refer to the verify(8) manual
-page for details. The address_verify_map (NOTE: singular) configuration parameter
-specifies an optional database for sender or recipient address
-verification results. If you don't specify a file, all address
-verification information is lost after "postfix reload" or "postfix
-stop". If your /var file system has sufficient space, try: To improve performance, the Postfix verify(8) daemon can save
+address verification results to a persistent database. The
+address_verify_map (NOTE: singular) configuration parameter specifies
+persistent storage for sender or recipient address verification
+results. If you specify an empty value, all address verification
+results are lost after "postfix reload" or "postfix stop". NOTE 1: As of version 2.5, Postfix no longer uses root privileges
-when opening this file. The file should now be stored under the
-Postfix-owned data_directory. As a migration aid, an attempt to
-open the file under a non-Postfix directory is redirected to the
-Postfix-owned data_directory, and a warning is logged. If you wish
-to continue using a pre-existing database file, move it to the
-data_directory, and change ownership to the account specified with
-the mail_owner parameter. NOTE 1: The database file should be stored under a Postfix-owned
+directory, such as $data_directory. NOTE 2: Do not put this file in a file system that may run out
of space. When the address verification table gets corrupted the
@@ -443,23 +440,28 @@ world comes to an end and YOU will have to MANUALLY fix things as
described in the next section. Meanwhile, you will not receive mail
via SMTP. NOTE 3: The verify(8) daemon process will create a new database when
-none exists, and will open/create the file before it enters the
+ NOTE 3: The verify(8) daemon will create a new database when
+none exists. It will open or create the file before entering the
chroot jail. The verify(8) manual page describes parameters that control
-how long information remains cached before it needs to be refreshed,
-and how long information can remain "unrefreshed" before it expires.
-Postfix uses different controls for positive results (address was
-accepted) and for negative results (address was rejected). The verify(8) manual page describes parameters that control how
+long address verification results are cached before they need to
+be refreshed, and how long results can remain "unrefreshed" before
+they expire. Postfix uses different controls for positive results
+(address was accepted) and for negative results (address was rejected,
+or address verification failed for some other reason). Right now, no tools are provided to manage the address verification
-database. If the file gets too big, or if it gets corrupted, you
-can manually rename or delete the file and run "postfix reload".
-The new verify daemon process will then create a new database. Current Postfix versions will periodically remove expired entries
+from the address verification database. With Postfix version 2.6
+and earlier, database cleanup had to be done as described next. If the address verification database file becomes too big, or
+if it becomes corrupted, the solution is to manually rename or
+delete (NOT: truncate) the file and run "postfix reload". The
+verify(8) daemon will then create a new database file. The amount of time between verify(8) cache cleanup runs. Cache
-cleanup increases the load on the cache database and should therefore
-not be run frequently. This feature requires that the cache database
+ The amount of time between verify(8) address verification
+database cleanup runs. This feature requires that the database
supports the "delete" and "sequence" operators. Specify a zero
-interval to disable cache cleanup. Address verification database
-
-
/etc/postfix/main.cf:
+ # Default setting for Postfix 2.7 and later.
# Note: avoid hash files here. Use btree instead.
- address_verify_map = btree:/var/lib/postfix/verify
+ address_verify_map = btree:$data_directory/verify_cache
+
+ # Default setting for Postfix 2.6 and earlier.
+ # This uses non-persistent storage only.
+ address_verify_map =
As of version 2.5, Postfix no longer uses root privileges
+when opening this file. To maintain backwards compatibility, an
+attempt to open the file under a non-Postfix directory is redirected
+to the Postfix-owned data_directory, and a warning is logged. If
+you wish to continue using a pre-existing database file, change its
+file ownership to the account specified with the mail_owner parameter,
+and either move the file to the data_directory, or move it to some
+other Postfix-owned directory.
Managing the address verification
database
-Controlling the routing of address
verification probes
diff --git a/postfix/html/postconf.5.html b/postfix/html/postconf.5.html
index 9bae584ca..955936e00 100644
--- a/postfix/html/postconf.5.html
+++ b/postfix/html/postconf.5.html
@@ -124,11 +124,10 @@ Do not change this unless you have a complete understanding of address_verify_cache_cleanup_interval
(default: 12h)
Time units: s (seconds), m (minutes), h (hours), d (days), w (weeks).
@@ -169,30 +168,32 @@ This feature is available in Postfix 2.1 and later.-Optional lookup table for persistent address verification status +Lookup table for persistent address verification status storage. The table is maintained by the verify(8) service, and is opened before the process releases privileges.
-By default, the information is kept in volatile memory, and is lost -after "postfix reload" or "postfix stop". +The lookup table is persistent by default as of Postfix version +2.7. Specify an empty table name to keep the information in volatile +memory which is lost after "postfix reload" or "postfix +stop" (this is default with earlier Postfix versions).
Specify a location in a file system that will not fill up. If the database becomes corrupted, the world comes to an end. To recover -delete the file and do "postfix reload". +delete (NOT: truncate) the file and do "postfix reload".
As of version 2.5, Postfix no longer uses root privileges when -opening this file. The file should now be stored under the Postfix-owned -data_directory. As a migration aid, an attempt to open the file -under a non-Postfix directory is redirected to the Postfix-owned -data_directory, and a warning is logged.
+opening this file. The file must now be stored under a Postfix-owned +directory such as the data_directory. As a migration aid, an attempt +to open the file under a non-Postfix directory is redirected to the +Postfix-owned data_directory, and a warning is logged.Examples: diff --git a/postfix/html/verify.8.html b/postfix/html/verify.8.html index 7143c1cb0..60df931ee 100644 --- a/postfix/html/verify.8.html +++ b/postfix/html/verify.8.html @@ -86,9 +86,9 @@ VERIFY(8) VERIFY(8) postconf(5) for more details including examples. CACHE CONTROLS - address_verify_map (empty) - Optional lookup table for persistent address veri- - fication status storage. + address_verify_map (see 'postconf -d' output) + Lookup table for persistent address verification + status storage. address_verify_sender ($double_bounce_sender) The sender address to use in address verification diff --git a/postfix/html/virtual.8.html b/postfix/html/virtual.8.html index 5064d787e..bff378fd7 100644 --- a/postfix/html/virtual.8.html +++ b/postfix/html/virtual.8.html @@ -236,21 +236,22 @@ VIRTUAL(8) VIRTUAL(8) the virtual message delivery transport. virtual_mailbox_limit (51200000) - The maximal size in bytes of an individual mailbox - or maildir file, or zero (no limit). + The maximal size in bytes of an individual vir- + tual(8) mailbox or maildir file, or zero (no + limit). MISCELLANEOUS CONTROLS config_directory (see 'postconf -d' output) - The default location of the Postfix main.cf and + The default location of the Postfix main.cf and master.cf configuration files. daemon_timeout (18000s) - How much time a Postfix daemon process may take to - handle a request before it is terminated by a + How much time a Postfix daemon process may take to + handle a request before it is terminated by a built-in watchdog timer. delay_logging_resolution_limit (2) - The maximal number of digits after the decimal + The maximal number of digits after the decimal point when logging sub-second delay values. ipc_timeout (3600s) @@ -258,33 +259,33 @@ VIRTUAL(8) VIRTUAL(8) over an internal communication channel. max_idle (100s) - The maximum amount of time that an idle Postfix - daemon process waits for an incoming connection + The maximum amount of time that an idle Postfix + daemon process waits for an incoming connection before terminating voluntarily. max_use (100) - The maximal number of incoming connections that a - Postfix daemon process will service before termi- + The maximal number of incoming connections that a + Postfix daemon process will service before termi- nating voluntarily. process_id (read-only) - The process ID of a Postfix command or daemon + The process ID of a Postfix command or daemon process. process_name (read-only) - The process name of a Postfix command or daemon + The process name of a Postfix command or daemon process. queue_directory (see 'postconf -d' output) - The location of the Postfix top-level queue direc- + The location of the Postfix top-level queue direc- tory. syslog_facility (mail) The syslog facility of Postfix logging. syslog_name (see 'postconf -d' output) - The mail system name that is prepended to the - process name in syslog records, so that "smtpd" + The mail system name that is prepended to the + process name in syslog records, so that "smtpd" becomes, for example, "postfix/smtpd". SEE ALSO @@ -297,20 +298,20 @@ VIRTUAL(8) VIRTUAL(8) VIRTUAL_README, domain hosting howto LICENSE - The Secure Mailer license must be distributed with this + The Secure Mailer license must be distributed with this software. HISTORY - This delivery agent was originally based on the Postfix - local delivery agent. Modifications mainly consisted of - removing code that either was not applicable or that was - not safe in this context: aliases, ~user/.forward files, + This delivery agent was originally based on the Postfix + local delivery agent. Modifications mainly consisted of + removing code that either was not applicable or that was + not safe in this context: aliases, ~user/.forward files, delivery to "|command" or to /file/name. The Delivered-To: message header appears in the qmail sys- tem by Daniel Bernstein. - The maildir structure appears in the qmail system by + The maildir structure appears in the qmail system by Daniel Bernstein. AUTHOR(S) diff --git a/postfix/man/man5/postconf.5 b/postfix/man/man5/postconf.5 index 7e5f62d27..d58f43a00 100644 --- a/postfix/man/man5/postconf.5 +++ b/postfix/man/man5/postconf.5 @@ -78,11 +78,10 @@ an \fBaccess\fR(5) map "reject" action. .PP Do not change this unless you have a complete understanding of RFC 2821. .SH address_verify_cache_cleanup_interval (default: 12h) -The amount of time between \fBverify\fR(8) cache cleanup runs. Cache -cleanup increases the load on the cache database and should therefore -not be run frequently. This feature requires that the cache database +The amount of time between \fBverify\fR(8) address verification +database cleanup runs. This feature requires that the database supports the "delete" and "sequence" operators. Specify a zero -interval to disable cache cleanup. +interval to disable database cleanup. .PP Time units: s (seconds), m (minutes), h (hours), d (days), w (weeks). @@ -98,23 +97,25 @@ Overrides the local_transport parameter setting for address verification probes. .PP This feature is available in Postfix 2.1 and later. -.SH address_verify_map (default: empty) -Optional lookup table for persistent address verification status +.SH address_verify_map (default: see "postconf -d" output) +Lookup table for persistent address verification status storage. The table is maintained by the \fBverify\fR(8) service, and is opened before the process releases privileges. .PP -By default, the information is kept in volatile memory, and is lost -after "\fBpostfix reload\fR" or "\fBpostfix stop\fR". +The lookup table is persistent by default as of Postfix version +2.7. Specify an empty table name to keep the information in volatile +memory which is lost after "\fBpostfix reload\fR" or "\fBpostfix +stop\fR" (this is default with earlier Postfix versions). .PP Specify a location in a file system that will not fill up. If the database becomes corrupted, the world comes to an end. To recover -delete the file and do "\fBpostfix reload\fR". +delete (NOT: truncate) the file and do "\fBpostfix reload\fR". .PP As of version 2.5, Postfix no longer uses root privileges when -opening this file. The file should now be stored under the Postfix-owned -data_directory. As a migration aid, an attempt to open the file -under a non-Postfix directory is redirected to the Postfix-owned -data_directory, and a warning is logged. +opening this file. The file must now be stored under a Postfix-owned +directory such as the data_directory. As a migration aid, an attempt +to open the file under a non-Postfix directory is redirected to the +Postfix-owned data_directory, and a warning is logged. .PP Examples: .PP diff --git a/postfix/man/man8/verify.8 b/postfix/man/man8/verify.8 index a73d8a6b6..e7d0b96e1 100644 --- a/postfix/man/man8/verify.8 +++ b/postfix/man/man8/verify.8 @@ -93,8 +93,8 @@ The text below provides only a parameter summary. See .nf .ad .fi -.IP "\fBaddress_verify_map (empty)\fR" -Optional lookup table for persistent address verification status +.IP "\fBaddress_verify_map (see 'postconf -d' output)\fR" +Lookup table for persistent address verification status storage. .IP "\fBaddress_verify_sender ($double_bounce_sender)\fR" The sender address to use in address verification probes; prior diff --git a/postfix/man/man8/virtual.8 b/postfix/man/man8/virtual.8 index b82beef4d..809474d9a 100644 --- a/postfix/man/man8/virtual.8 +++ b/postfix/man/man8/virtual.8 @@ -245,8 +245,8 @@ via the virtual message delivery transport. The maximal number of recipients per message for the virtual message delivery transport. .IP "\fBvirtual_mailbox_limit (51200000)\fR" -The maximal size in bytes of an individual mailbox or maildir file, -or zero (no limit). +The maximal size in bytes of an individual \fBvirtual\fR(8) mailbox or +maildir file, or zero (no limit). .SH "MISCELLANEOUS CONTROLS" .na .nf diff --git a/postfix/proto/ADDRESS_VERIFICATION_README.html b/postfix/proto/ADDRESS_VERIFICATION_README.html index 973e5095c..4f8d55e3a 100644 --- a/postfix/proto/ADDRESS_VERIFICATION_README.html +++ b/postfix/proto/ADDRESS_VERIFICATION_README.html @@ -402,40 +402,37 @@ sender address verification probe fails with some temporary error.
NOTE: By default, address verification information is not stored -in a persistent file. You have to specify one in main.cf (see -below). Persistent storage is off by default because it may need -more disk space than is available in your file system.
- -Address verification information is cached by the Postfix verify -daemon. Postfix has a bunch of parameters that control the caching -of positive and negative results. Refer to the verify(8) manual -page for details.
- -The address_verify_map (NOTE: singular) configuration parameter -specifies an optional database for sender or recipient address -verification results. If you don't specify a file, all address -verification information is lost after "postfix reload" or "postfix -stop".
- -If your /var file system has sufficient space, try:
+To improve performance, the Postfix verify(8) daemon can save +address verification results to a persistent database. The +address_verify_map (NOTE: singular) configuration parameter specifies +persistent storage for sender or recipient address verification +results. If you specify an empty value, all address verification +results are lost after "postfix reload" or "postfix stop".
-/etc/postfix/main.cf: + # Default setting for Postfix 2.7 and later. # Note: avoid hash files here. Use btree instead. - address_verify_map = btree:/var/lib/postfix/verify + address_verify_map = btree:$data_directory/verify_cache + + # Default setting for Postfix 2.6 and earlier. + # This uses non-persistent storage only. + address_verify_map =
NOTE 1: As of version 2.5, Postfix no longer uses root privileges -when opening this file. The file should now be stored under the -Postfix-owned data_directory. As a migration aid, an attempt to -open the file under a non-Postfix directory is redirected to the -Postfix-owned data_directory, and a warning is logged. If you wish -to continue using a pre-existing database file, move it to the -data_directory, and change ownership to the account specified with -the mail_owner parameter.
+NOTE 1: The database file should be stored under a Postfix-owned +directory, such as $data_directory.
+ +As of version 2.5, Postfix no longer uses root privileges +when opening this file. To maintain backwards compatibility, an +attempt to open the file under a non-Postfix directory is redirected +to the Postfix-owned data_directory, and a warning is logged. If +you wish to continue using a pre-existing database file, change its +file ownership to the account specified with the mail_owner parameter, +and either move the file to the data_directory, or move it to some +other Postfix-owned directory.
NOTE 2: Do not put this file in a file system that may run out of space. When the address verification table gets corrupted the @@ -443,23 +440,28 @@ world comes to an end and YOU will have to MANUALLY fix things as described in the next section. Meanwhile, you will not receive mail via SMTP.
-NOTE 3: The verify(8) daemon process will create a new database when -none exists, and will open/create the file before it enters the +
NOTE 3: The verify(8) daemon will create a new database when +none exists. It will open or create the file before entering the chroot jail.
The verify(8) manual page describes parameters that control -how long information remains cached before it needs to be refreshed, -and how long information can remain "unrefreshed" before it expires. -Postfix uses different controls for positive results (address was -accepted) and for negative results (address was rejected).
+The verify(8) manual page describes parameters that control how +long address verification results are cached before they need to +be refreshed, and how long results can remain "unrefreshed" before +they expire. Postfix uses different controls for positive results +(address was accepted) and for negative results (address was rejected, +or address verification failed for some other reason).
-Right now, no tools are provided to manage the address verification -database. If the file gets too big, or if it gets corrupted, you -can manually rename or delete the file and run "postfix reload". -The new verify daemon process will then create a new database.
+Current Postfix versions will periodically remove expired entries +from the address verification database. With Postfix version 2.6 +and earlier, database cleanup had to be done as described next.
+ +If the address verification database file becomes too big, or +if it becomes corrupted, the solution is to manually rename or +delete (NOT: truncate) the file and run "postfix reload". The +verify(8) daemon will then create a new database file.
-Optional lookup table for persistent address verification status +Lookup table for persistent address verification status storage. The table is maintained by the verify(8) service, and is opened before the process releases privileges.
-By default, the information is kept in volatile memory, and is lost -after "postfix reload" or "postfix stop". +The lookup table is persistent by default as of Postfix version +2.7. Specify an empty table name to keep the information in volatile +memory which is lost after "postfix reload" or "postfix +stop" (this is default with earlier Postfix versions).
Specify a location in a file system that will not fill up. If the database becomes corrupted, the world comes to an end. To recover -delete the file and do "postfix reload". +delete (NOT: truncate) the file and do "postfix reload".
- +As of version 2.5, Postfix no longer uses root privileges when -opening this file. The file should now be stored under the Postfix-owned -data_directory. As a migration aid, an attempt to open the file -under a non-Postfix directory is redirected to the Postfix-owned -data_directory, and a warning is logged.
+opening this file. The file must now be stored under a Postfix-owned +directory such as the data_directory. As a migration aid, an attempt +to open the file under a non-Postfix directory is redirected to the +Postfix-owned data_directory, and a warning is logged.Examples: @@ -282,11 +284,10 @@ This feature is available in Postfix 2.1 and later. %PARAM address_verify_cache_cleanup_interval 12h -
The amount of time between verify(8) cache cleanup runs. Cache -cleanup increases the load on the cache database and should therefore -not be run frequently. This feature requires that the cache database +
The amount of time between verify(8) address verification +database cleanup runs. This feature requires that the database supports the "delete" and "sequence" operators. Specify a zero -interval to disable cache cleanup.
+interval to disable database cleanup.Time units: s (seconds), m (minutes), h (hours), d (days), w (weeks).
diff --git a/postfix/src/global/mail_version.h b/postfix/src/global/mail_version.h index ef6c78c8c..5e5a8d5e2 100644 --- a/postfix/src/global/mail_version.h +++ b/postfix/src/global/mail_version.h @@ -20,7 +20,7 @@ * Patches change both the patchlevel and the release date. Snapshots have no * patchlevel; they change the release date only. */ -#define MAIL_RELEASE_DATE "20100101" +#define MAIL_RELEASE_DATE "20100102" #define MAIL_VERSION_NUMBER "2.7" #ifdef SNAPSHOT diff --git a/postfix/src/util/Makefile.in b/postfix/src/util/Makefile.in index 4a8088840..653919c85 100644 --- a/postfix/src/util/Makefile.in +++ b/postfix/src/util/Makefile.in @@ -498,6 +498,12 @@ dict_cidr_test: dict_open dict_cidr.in dict_cidr.map dict_cidr.ref diff dict_cidr.ref dict_cidr.tmp rm -f dict_cidr.tmp +dict_seq_test: dict_open testdb dict_seq.in dict_seq.ref + rm -f testdb.db testdb.dir testdb.pag + ./dict_open hash:testdb create sync < dict_seq.in > dict_seq.tmp 2>&1 + diff dict_seq.ref dict_seq.tmp + rm -f testdb.db testdb.dir testdb.pag dict_seq.tmp + host_port_test: host_port host_port.in host_port.ref ./host_port