From 281c119f28154d4ab319c1313ae845250348a9e8 Mon Sep 17 00:00:00 2001 From: "James E. Blair" Date: Wed, 31 Jul 2013 17:20:32 -0700 Subject: [PATCH] Further tuning of lists Up to 50 simultaneous queue runners Run queues every minute Also adds queue_smtp_domains as a parameter (unused currently). Change-Id: I7d93131278e5d8677445e3230f68b2a81313246a --- modules/exim/manifests/init.pp | 1 + modules/exim/templates/exim4.conf.erb | 27 ++++++++++++++++++++ modules/openstack_project/manifests/lists.pp | 3 ++- 3 files changed, 30 insertions(+), 1 deletion(-) diff --git a/modules/exim/manifests/init.pp b/modules/exim/manifests/init.pp index d927411790..272e2be478 100644 --- a/modules/exim/manifests/init.pp +++ b/modules/exim/manifests/init.pp @@ -1,6 +1,7 @@ class exim( $mailman_domains = [], $queue_interval = '30m', + $queue_run_max = '5', $sysadmin = [] ) { diff --git a/modules/exim/templates/exim4.conf.erb b/modules/exim/templates/exim4.conf.erb index 6d9965f5fc..7fb1ff07e4 100644 --- a/modules/exim/templates/exim4.conf.erb +++ b/modules/exim/templates/exim4.conf.erb @@ -290,6 +290,33 @@ timeout_frozen_after = 7d # split_spool_directory = true +# This controls the maximum number of queue runner processes that an +# Exim daemon can run simultaneously. This does not mean that it +# starts them all at once, but rather that if the maximum number are +# still running when the time comes to start another one, it refrains +# from starting another one. This can happen with very large queues +# and/or very sluggish deliveries. This option does not, however, +# interlock with other processes, so additional queue runners can be +# started by other means, or by killing and restarting the daemon. + +queue_run_max = <%= queue_run_max %> + +# When this option is set, a delivery process is started whenever a +# message is received, routing is performed, and local deliveries take +# place. However, if any SMTP deliveries are required for domains that +# match queue_smtp_domains, they are not immediately delivered, but +# instead the message waits on the queue for the next queue run. Since +# routing of the message has taken place, Exim knows to which remote +# hosts it must be delivered, and so when the queue run happens, +# multiple messages for the same host are delivered over a single SMTP +# connection. The -odqs command line option causes all SMTP deliveries +# to be queued in this way, and is equivalent to setting +# queue_smtp_domains to "*". See also hold_domains and queue_domains. + +<% if queue_smtp_domains != "" -%> +queue_smtp_domains = <%= queue_smtp_domains %> +<% end %> + <% if mailman_domains.length > 0 -%> # Home dir for your Mailman installation -- aka Mailman's prefix # directory. diff --git a/modules/openstack_project/manifests/lists.pp b/modules/openstack_project/manifests/lists.pp index 23dfc45fbf..5b0c894bbe 100644 --- a/modules/openstack_project/manifests/lists.pp +++ b/modules/openstack_project/manifests/lists.pp @@ -15,7 +15,8 @@ class openstack_project::lists( class { 'exim': sysadmin => $listadmins, - queue_interval => '5m', + queue_interval => '1m', + queue_run_max => '50', mailman_domains => [$listdomain], }