« Return to Thread: Using %D in the logfile directive in a filter?

Re: Using %D in the logfile directive in a filter?

by Adam Funk-4 :: Rate this Message:

Reply to Author | View in Thread

On 2009-07-02, Phil Pennock wrote:

> On 2009-07-02 at 15:25 +0100, Adam Funk wrote:

>> I was told that %D would expand to 20090602 as it does in Exim's own
>> logfiles, but it isn't working; the directive
>>
>>   logfile  $home/mail_logs/test_%D.log
>>
>> puts the file in "~/mail_logs/test_%D.log".

> The string expansion of %X, for various X, is not done for the logfile
> directive of filters.  It's only for the normal Exim logs.
>
> You do have access to all of Exim's string expansion variables (except
> for those explicitly prohibited in config); you should just be able to
> use $tod_logfile instead of %D.

Perfect, thanks very much!  I guess if I want to switch to monthly
logs, I could also use "${substr_0_4:$tod_logfile}".

BTW, I have one other concern.  Is it possible for a badly written
logfile or logwrite instruction in a filter to cause mail to be lost?


--
## List details at http://lists.exim.org/mailman/listinfo/exim-users 
## Exim details at http://www.exim.org/
## Please use the Wiki with this list - http://wiki.exim.org/

 « Return to Thread: Using %D in the logfile directive in a filter?