[Dovecot] doveadm expunge info message in std.error
Hello
This command
doveadm expunge -u "user@domain" mailbox ".namespace/*" savedbefore 7d
writes these messages to std.error
doveadm(user@domain): Info: expunge: box=.namespace/INBOX, uid=5932, msgid=<E1Puxwf-0001fD-Si@hostname>, size=1824 doveadm(user@domain): Info: expunge: box=.namespace/INBOX, uid=5933, msgid=<E1Puy0N-0001fI-No@hostname>, size=1822 doveadm(user@domain): Info: expunge: box=.namespace/INBOX, uid=5934, msgid=<E1Puy0Q-0001fM-I0@hostname>, size=1824 doveadm(user@domain): Info: expunge: box=.namespace/INBOX, uid=5935, msgid=<E1Pv6CY-0001ge-H9@hostname>, size=1843 doveadm(user@domain): Info: expunge: box=.namespace/INBOX, uid=5936, msgid=<E1Pv6Hm-0001gi-7R@hostname>, size=1822 doveadm(user@domain): Info: expunge: box=.namespace/INBOX, uid=5937, msgid=<E1PvMRn-0001lm-A6@hostname>, size=1854 doveadm(user@domain): Info: expunge: box=.namespace/INBOX, uid=5938, msgid=<E1PvZLN-0001p4-EF@hostname>, size=1832 doveadm(user@domain): Info: expunge: box=.namespace/INBOX, uid=5939, msgid=<E1PvZN6-0001p8-IA@hostname>, size=1840 doveadm(user@domain): Info: expunge: box=.namespace/INBOX, uid=5940, msgid=<E1PwMvo-0001xs-8w@hostname>, size=1835
Can we write these messages(informational) to std.out
It would help reduce cron mails.
Thanks KuiZ
On 03/16/2011 08:00 PM Kui Zhang wrote:
Hello
This command
doveadm expunge -u "user@domain" mailbox ".namespace/*" savedbefore 7d
writes these messages to std.error
doveadm(user@domain): Info: expunge: box=.namespace/INBOX, uid=5932, msgid=<E1Puxwf-0001fD-Si@hostname>, size=1824 …
Can we write these messages(informational) to std.out
It would help reduce cron mails.
Yes - we can. :-)
doveadm expunge -u "user@domain" mailbox ... 2>&1
But cron will send you mails with stdout output too. AFAIK
Regards, Pascal
The trapper recommends today: deadbeef.1107520@localdomain.org
Sorry, I was not very clear on my request...
I dont want emails from cron unless there is a problem.
I was hopping Timo could patch the expunge call. So information messages go to std.out and errors to std.error..
Thanks KuiZ
On Wed, Mar 16, 2011 at 12:47 PM, Pascal Volk <user+dovecot@localhost.localdomain.org> wrote:
On 03/16/2011 08:00 PM Kui Zhang wrote:
Hello
This command
doveadm expunge -u "user@domain" mailbox ".namespace/*" savedbefore 7d
writes these messages to std.error
doveadm(user@domain): Info: expunge: box=.namespace/INBOX, uid=5932, msgid=<E1Puxwf-0001fD-Si@hostname>, size=1824 …
Can we write these messages(informational) to std.out
It would help reduce cron mails.
Yes - we can. :-)
doveadm expunge -u "user@domain" mailbox ... 2>&1
But cron will send you mails with stdout output too. AFAIK
Regards, Pascal
The trapper recommends today: deadbeef.1107520@localdomain.org
On Wed, 2011-03-16 at 12:00 -0700, Kui Zhang wrote:
doveadm expunge -u "user@domain" mailbox ".namespace/*" savedbefore 7d
writes these messages to std.error
doveadm(user@domain): Info: expunge: box=.namespace/INBOX, uid=5932, msgid=<E1Puxwf-0001fD-Si@hostname>, size=1824
You should be able to get rid of these with:
doveadm -o plugin/mail_log_events= expunge ..
Can we write these messages(informational) to std.out
I thought about this too, but I think in the end it could lead to trouble. Several doveadm commands already output replies to stdout, so not all commands can have their Info: logs outputted to stdout. And having some commands do that and others not isn't very consistent.
participants (3)
-
Kui Zhang
-
Pascal Volk
-
Timo Sirainen