Am 06.05.2014 15:08 schrieb Mark Martinec via amavis-users:
> A release candidade of the coming version 2.9.0 of amavisd-new
> is available at:

Mark,

at first I like to thank you for your valueable work.

Anyway I have some patches I like to see upstream. Maybe there is a chance to 
integrate them
As I found them usefull for me and maybe for others too.

1. unique_log_id_in_miltermode.patch
Only via amavisd-milter the logged message-id aren't unique. There is no 
increasing child number.

2. silent_reload.patch
On reload amavisd prints some messages on stdout. That's fine on interactive 
invovation.
But if called via cron it triggers a mail sent out by cron.
OK, one can setup the cron to be silent, but I personaly dislike "> /dev/null" 
in cronjobs.
I don't want to make me blind ...

3. less_logging_in_miltermode.patch
Some loglines are not really usefull for me because they contain no relevant 
information
(compared to the selected loglevel, my opinion)
So I changed the loglevel.

Andreas

-- 
Andreas Schulze
Internetdienste | P252

DATEV eG
90329 Nürnberg | Telefon +49 911 319-0 | Telefax +49 911 319-3196
E-Mail info @datev.de | Internet www.datev.de
Sitz: 90429 Nürnberg, Paumgartnerstr. 6-14 | Registergericht Nürnberg, GenReg 
Nr.70
Vorstand
Prof. Dieter Kempf (Vorsitzender)
Dipl.-Kfm. Wolfgang Stegmann (stellvertretender Vorsitzender)
Dipl.-Kfm. Dr. Robert Mayr
Jörg Rabe v. Pappenheim
Dipl.-Vw. Eckhard Schwarzer
Vorsitzender des Aufsichtsrates: Reinhard Verholen
Index: amavisd-new-2.9.0-rc1/amavisd
===================================================================
--- amavisd-new-2.9.0-rc1.orig/amavisd	2014-05-07 11:45:47.000000000 +0200
+++ amavisd-new-2.9.0-rc1/amavisd	2014-05-07 11:45:50.000000000 +0200
@@ -11833,7 +11833,7 @@
     $current_policy_bank{'policy_bank_path'} =
       ($cpbp eq '' ? '' : $cpbp.'/') . $policy_bank_name;
     update_current_log_level();
-    do_log(2,'loaded policy bank "%s"%s', $policy_bank_name,
+    do_log(3,'loaded policy bank "%s"%s', $policy_bank_name,
                      $cpbp eq '' ? '' : " over \"$cpbp\"");
   }
 }
@@ -20271,7 +20271,7 @@
     $msginfo->log_id(am_id());
   }
   if ($ampdp) {
-    do_log(1, "Request: %s %s %s: %s -> %s", $attr_ref->{'request'},
+    do_log(3, "Request: %s %s %s: %s -> %s", $attr_ref->{'request'},
               $attr_ref->{'mail_id'}, $msginfo->mail_tempdir,
               $msginfo->sender_smtp,
               join(',', map($_->recip_addr_smtp, @recips)) );
@@ -20479,7 +20479,7 @@
     push(@response, proto_encode('return_value','continue'));
   }
   push(@response, proto_encode('exit_code',sprintf("%d",$exit_code)));
-  ll(2) && do_log(2, "mail checking ended: %s", join("\n",@response));
+  ll(3) && do_log(3, "mail checking ended: %s", join("\n",@response));
   dump_captured_log(1, c('enable_log_capture_dump'));
   %current_policy_bank = %baseline_policy_bank;  # restore bank settings
   @response;
Index: amavisd-new-2.9.0-rc1/amavisd
===================================================================
--- amavisd-new-2.9.0-rc1.orig/amavisd	2014-05-07 11:45:54.000000000 +0200
+++ amavisd-new-2.9.0-rc1/amavisd	2014-05-07 11:45:57.000000000 +0200
@@ -20241,7 +20241,7 @@
     } else {  # mail checking or releasing from a file
       do_log(5, "preprocess_policy_query: opening mail '%s'", $fname);
       # set new amavis message id
-      new_am_id( ($fname =~ m{amavis-(milter-)?([^/ \t]+)}s ? $2 : undef) )
+      new_am_id( ($fname =~ m{amavis-(milter-)?([^/ \t]+)}s ? $2 : undef), $Amavis::child_invocation_count)
         if !$releasing;
       # file created by amavis helper program or other client, just open it
       my(@stat_list) = lstat($fname); my $errn = @stat_list ? 0 : 0+$!;
Index: amavisd-new-2.9.0-rc1/amavisd
===================================================================
--- amavisd-new-2.9.0-rc1.orig/amavisd	2014-05-07 11:45:50.000000000 +0200
+++ amavisd-new-2.9.0-rc1/amavisd	2014-05-07 11:45:54.000000000 +0200
@@ -18117,7 +18117,7 @@
     kill('HUP',$amavisd_pid) or $! == ESRCH
       or die "Can't SIGHUP amavisd[$amavisd_pid]: $!";
     my $msg = "Signalling a SIGHUP to a running daemon [$amavisd_pid]";
-    do_log(2,"%s",$msg);  print STDOUT "$msg\n";
+    do_log(2,"%s",$msg);
     exit(0);
   } elsif ($cmd =~ /^(?:restart|stop)\z/) {  # stop or restart
     defined $amavisd_pid or die "The amavisd daemon is not running\n";

Reply via email to