(2.4) weird doveadm behavior
debian package 2.4.1-4 (7d8c0e5759): /etc/dovecot/dovecot.conf I have namespace: namespace expunged { mail_driver = maildir mail_path = ~/Mail/expunged/ mailbox_list_layout = fs hidden = yes inbox = no list = no prefix = .EXPUNGED/ separator = / }
%doveadm search -u kjonca mailbox .EXPUNGED|head -n 1 08ac303413c11168864d2a00a6f72b09 30802 %doveadm fetch -u kjonca text mailbox-guid 08ac303413c11168864d2a00a6f72b09 uid 30802
...empty output...
How can I fetch messages? KJ
-- http://wolnelektury.pl/wesprzyj/teraz/ Now KEN and BARBIE are PERMANENTLY ADDICTED to MIND-ALTERING DRUGS ...
don't send the output to head -n1 and you'll get more than one line if the data is there :-)
On 05/05/2025 17:01, Kamil Jońca via dovecot wrote:
debian package 2.4.1-4 (7d8c0e5759): /etc/dovecot/dovecot.conf I have namespace: namespace expunged { mail_driver = maildir mail_path = ~/Mail/expunged/ mailbox_list_layout = fs hidden = yes inbox = no list = no prefix = .EXPUNGED/ separator = / }
%doveadm search -u kjonca mailbox .EXPUNGED|head -n 1 08ac303413c11168864d2a00a6f72b09 30802 %doveadm fetch -u kjonca text mailbox-guid 08ac303413c11168864d2a00a6f72b09 uid 30802
...empty output...
How can I fetch messages? KJ
-- This email has been checked for viruses by AVG antivirus software. www.avg.com
Tim Dickson via dovecot <dovecot@dovecot.org> writes:
don't send the output to head -n1 and you'll get more than one line if the data is there :-)
Could you please elaborate? head -n 1 is to get only one message ids (and it works - as you could see)
but trying to fetch this message fails (and this command is not piped to "head")
KJ
http://wolnelektury.pl/wesprzyj/teraz/ We were so poor we couldn't afford a watchdog. If we heard a noise at night, we'd bark ourselves. -- Crazy Jimmy
On 5. May 2025, at 19.01, Kamil Jońca via dovecot <dovecot@dovecot.org> wrote:
debian package 2.4.1-4 (7d8c0e5759): /etc/dovecot/dovecot.conf I have namespace: namespace expunged { mail_driver = maildir mail_path = ~/Mail/expunged/ mailbox_list_layout = fs hidden = yes inbox = no list = no prefix = .EXPUNGED/ separator = / }
%doveadm search -u kjonca mailbox .EXPUNGED|head -n 1 08ac303413c11168864d2a00a6f72b09 30802 %doveadm fetch -u kjonca text mailbox-guid 08ac303413c11168864d2a00a6f72b09 uid 30802
...empty output...
How can I fetch messages?
Looks like unless you explicitly specify "mailbox" parameter, it's skipping the list=no namespaces. Pretty sure v2.3 worked the same way. You could just bypass the "doveadm search" step?
Timo Sirainen via dovecot <dovecot@dovecot.org> writes:
[...]
Looks like unless you explicitly specify "mailbox" parameter, it's skipping the list=no namespaces. Pretty sure v2.3 worked the same way. You could just bypass the "doveadm search" step?
I am afraid not. this comes from script which works like: find some emails and then do something for each email. KJ
-- http://wolnelektury.pl/wesprzyj/teraz/ Bachelor: A man who chases women and never Mrs. one.
On 6. May 2025, at 11.47, Kamil Jońca via dovecot <dovecot@dovecot.org> wrote:
Timo Sirainen via dovecot <dovecot@dovecot.org> writes:
[...]
Looks like unless you explicitly specify "mailbox" parameter, it's skipping the list=no namespaces. Pretty sure v2.3 worked the same way. You could just bypass the "doveadm search" step?
I am afraid not. this comes from script which works like: find some emails and then do something for each email.
You could work around with: doveadm -o namespace/expunged/list=yes fetch ...
Or in config:
protocol doveadm { namespace expunged { list = yes } }
Kamil Jońca via dovecot <dovecot@dovecot.org> writes:
[...]
%doveadm search -u kjonca mailbox .EXPUNGED|head -n 1 08ac303413c11168864d2a00a6f72b09 30802
its even more weird for me:
(there is only one email in z/1 mailbox)
--8<---------------cut here---------------start------------->8---
kjonca@alfa:~%doveadm search -u kjonca mailbox .EXPUNGED|wc -l
80
kjonca@alfa:~%doveadm search -u kjonca mailbox .EXPUNGED or mailbox z/1|wc -l
1
kjonca@alfa:~%doveadm search -u kjonca mailbox z/1|wc -l
1
--8<---------------cut here---------------end--------------->8---
-- http://wolnelektury.pl/wesprzyj/teraz/ Death is nature's way of telling you to slow down.
participants (3)
-
Kamil Jońca
-
Tim Dickson
-
Timo Sirainen