another try listing expunged mail, now only tested with dovecot cli

2021-03-15 Thread Marc
testing with expunging messages with subject "delete me"

this is the correct commend to list expunged messages?

[@ testtest]# doveadm -o 
mail_location=mdbox_deleted:/home/popusers/testtest/mdbox:INDEX=/home/popindex/testtest/index
 mailbox status -u testtest 'messages vsize' '*'
Sent messages=0 vsize=0
Drafts messages=0 vsize=0
INBOX/test2 messages=0 vsize=0
Junk messages=0 vsize=0
Trash messages=0 vsize=0
test3 messages=0 vsize=0
test1 messages=0 vsize=0
INBOX messages=0 vsize=0


We have a few messages with subject 'delete me' in the inbox namespace

[@ ~]# doveadm search -u testtest mailbox test1 subject 'delete me' | wc -l
4
[@ ~]# doveadm search -u testtest mailbox INBOX/test2 subject 'delete me' | wc 
-l
2
[@ ~]# doveadm search -u testtest mailbox test3 subject 'delete me' | wc -l
8


Disk space used

[@ testtest]# du -s -k /home/popusers/testtest/mdbox/storage/
135356  /home/popusers/testtest/mdbox/storage/

Ok lets expunge some emails

[@ testtest]# doveadm expunge -u testtest mailbox test1 subject 'delete me'
doveadm(testtest): Info: expunge: box=test1, 
msgid=<202011052050.0a5ko7jc005...@web01.xx.>
doveadm(testtest): Info: expunge: box=test1, 
msgid=<202011052050.0a5ko7jc005...@web01.xx.>
doveadm(testtest): Info: expunge: box=test1, 
msgid=<202011052050.0a5ko7jc005...@web01.xx.>
doveadm(testtest): Info: expunge: box=test1, 
msgid=<202011052050.0a5ko7jc005...@web01.xx.>

[@ testtest]# doveadm expunge -u testtest mailbox INBOX/test2 subject 'delete 
me'
doveadm(testtest): Info: expunge: box=INBOX/test2, 
msgid=<202011052050.0a5ko7jc005...@web01.xx.>
doveadm(testtest): Info: expunge: box=INBOX/test2, 
msgid=<202011052050.0a5ko7jc005...@web01.xx.>

[@ testtest]# doveadm expunge -u testtest mailbox test3 subject 'delete me'
doveadm(testtest): Info: expunge: box=test3, 
msgid=<202011052050.0a5ko7jc005...@web01.xx.>
doveadm(testtest): Info: expunge: box=test3, 
msgid=<202011052050.0a5ko7jc005...@web01.xx.>
doveadm(testtest): Info: expunge: box=test3, 
msgid=<202011052050.0a5ko7jc005...@web01.xx.>
doveadm(testtest): Info: expunge: box=test3, 
msgid=<202011052050.0a5ko7jc005...@web01.xx.>
doveadm(testtest): Info: expunge: box=test3, 
msgid=<202011052050.0a5ko7jc005...@web01.xx.>
doveadm(testtest): Info: expunge: box=test3, 
msgid=<202011052050.0a5ko7jc005...@web01.xx.>
doveadm(testtest): Info: expunge: box=test3, 
msgid=<202011052050.0a5ko7jc005...@web01.xx.>
doveadm(testtest): Info: expunge: box=test3, 
msgid=<202011052050.0a5ko7jc005...@web01.xx.>

Looks like the correct amount of messages are deleted

[@ testtest]# du -s -k /home/popusers/testtest/mdbox/storage/
135356  /home/popusers/testtest/mdbox/storage/

Lets check the expunged mail, again still everywhere 0

[@ testtest]# doveadm -o 
mail_location=mdbox_deleted:/home/popusers/testtest/mdbox:INDEX=/home/popindex/testtest/index
 mailbox status -u testtest 'messages vsize' '*'
Sent messages=0 vsize=0
Drafts messages=0 vsize=0
INBOX/test2 messages=0 vsize=0
Junk messages=0 vsize=0
Trash messages=0 vsize=0
test3 messages=0 vsize=0
test1 messages=0 vsize=0
INBOX messages=0 vsize=0


This does not return any messages, so they were expunged.

[@ testtest]# doveadm search -u testtest  mailbox test3 subject 'delete me'

How can I get the amount of messages expunged in the folders? I do not get it.






RE: dovecot.map.index corrupted: Unexpectedly lost INBOX uid=1 map_uid=4726

2021-03-15 Thread Marc
> 
> I had in my archive namespace[1] an INBOX folder and did not really get
> why it was there so I deleted it. Now this command generates map index
> error (doveadm force-resync does not fix it ;))
> 
> 
> [@ ~]# doveadm -o namespace/4archives/location=mdbox_deleted:/home/mail-
> archive/testtest/mdbox/Archive -o
> mail_location=mdbox_deleted:/home/mail-
> archive/testtest/mdbox/Archive:INDEX=/home/archiveindex/testtest/index
> mailbox status -u testtest 'messages vsize' 'INBOX'
> 
> doveadm(testtest): Error: mdbox map
> /home/archiveindex/testtest/index/storage/dovecot.map.index corrupted:
> Unexpectedly lost INBOX uid=1 map_uid=4726
> doveadm(testtest): Error: Mailbox INBOX: Failed to lookup mailbox
> status: mdbox map
> /home/archiveindex/testtest/index/storage/dovecot.map.index corrupted:
> Unexpectedly lost INBOX uid=1 map_uid=4726
> 
> 

doveadm purge -u testtest

fixed this


dovecot.map.index corrupted: Unexpectedly lost INBOX uid=1 map_uid=4726

2021-03-15 Thread Marc

I had in my archive namespace[1] an INBOX folder and did not really get why it 
was there so I deleted it. Now this command generates map index error (doveadm 
force-resync does not fix it ;))


[@ ~]# doveadm -o 
namespace/4archives/location=mdbox_deleted:/home/mail-archive/testtest/mdbox/Archive
 -o 
mail_location=mdbox_deleted:/home/mail-archive/testtest/mdbox/Archive:INDEX=/home/archiveindex/testtest/index
 mailbox status -u testtest 'messages vsize' 'INBOX'

doveadm(testtest): Error: mdbox map 
/home/archiveindex/testtest/index/storage/dovecot.map.index corrupted: 
Unexpectedly lost INBOX uid=1 map_uid=4726
doveadm(testtest): Error: Mailbox INBOX: Failed to lookup mailbox status: mdbox 
map /home/archiveindex/testtest/index/storage/dovecot.map.index corrupted: 
Unexpectedly lost INBOX uid=1 map_uid=4726





[1] 
namespace 4archives {
  disabled = no
  hidden = no
  ignore_on_failure = no
  inbox = no
  list = yes
  location = 
mdbox:/home/mail-archive/%u/Archive/:CONTROL=/home/mail-archive/%u/Archive/control:INDEX=/home/archiveindex/%u/index
  mailbox Archive {
auto = create
autoexpunge = 0
autoexpunge_max_mails = 0
comment =
driver =
special_use = \Archive
  }
  mailbox "Archived mail" {
auto = no
autoexpunge = 0
autoexpunge_max_mails = 0
comment =
driver =
special_use = \Archive
  }
  mailbox "Archived messages" {
auto = no
autoexpunge = 0
autoexpunge_max_mails = 0
comment =
driver =
special_use = \Archive
  }
...
...
  mailbox Archives {
auto = no
autoexpunge = 0
autoexpunge_max_mails = 0
comment =
driver =
special_use = \Archive
  }
  order = 0
  prefix = Archive/
  separator = /
  subscriptions = yes
  type = private
}


Re: dovecot director and keepalived

2021-03-15 Thread Paterakis E. Ioannis



On 15/3/2021 9:11 μ.μ., Aki Tuomi wrote:

On 15/03/2021 20:54 Paterakis E. Ioannis  wrote:

  
On 15/3/2021 6:09 μ.μ., Steven Varco wrote:

Hi John

Thanks for you input.

So you basically state that („physically“) separating the director servers from 
keepalive/haproxy servers is the only option?
I would like to avoid setting up two additional machines for that whenever 
possible, as any node more in the chain potentially is another point of 
failure… ;)

Nope, it's not the only option. You can always have all three daemons
(keepalived/haproxy/director) on each machine. Keepalived will handle
the floating ip job, haproxies will have no problems with the floating
ip, the directors will always be binded to the static ips of the
machines and have their setup in the haproxies. That's all.

But, if you plan to make a Highly available environment, u have to
consider splitting your services to different VMs, and them to different
hypervisors in order to be as Highly available as you can

John

The point of dovecot director is that it acts as a proxy that always routes 
users to same backend. You can use keepalived, if it supports external 
commands, to maybe tell director which backends are up / down.


It's not keepalived's work to tell the directors which backend is 
up/down. You can use poolmon for that. keepalived will make sure the 
floating ip will always be assigned on an alive haproxy. Then it's 
haproxies' work to check the aliveness of directors. Then It's Directors 
job to assign the users to the same dovecot backend all the time, and so 
on


Don't mix things.

J



Re: dovecot director and keepalived

2021-03-15 Thread Aki Tuomi


> On 15/03/2021 20:54 Paterakis E. Ioannis  wrote:
> 
>  
> On 15/3/2021 6:09 μ.μ., Steven Varco wrote:
> > Hi John
> >
> > Thanks for you input.
> >
> > So you basically state that („physically“) separating the director servers 
> > from keepalive/haproxy servers is the only option?
> > I would like to avoid setting up two additional machines for that whenever 
> > possible, as any node more in the chain potentially is another point of 
> > failure… ;)
> 
> Nope, it's not the only option. You can always have all three daemons 
> (keepalived/haproxy/director) on each machine. Keepalived will handle 
> the floating ip job, haproxies will have no problems with the floating 
> ip, the directors will always be binded to the static ips of the 
> machines and have their setup in the haproxies. That's all.
> 
> But, if you plan to make a Highly available environment, u have to 
> consider splitting your services to different VMs, and them to different 
> hypervisors in order to be as Highly available as you can
> 
> John

The point of dovecot director is that it acts as a proxy that always routes 
users to same backend. You can use keepalived, if it supports external 
commands, to maybe tell director which backends are up / down.

You should have separate server for director(s) and each backend.

Aki


Re: dovecot director and keepalived

2021-03-15 Thread Paterakis E. Ioannis



On 15/3/2021 6:09 μ.μ., Steven Varco wrote:

Hi John

Thanks for you input.

So you basically state that („physically“) separating the director servers from 
keepalive/haproxy servers is the only option?
I would like to avoid setting up two additional machines for that whenever 
possible, as any node more in the chain potentially is another point of 
failure… ;)


Nope, it's not the only option. You can always have all three daemons 
(keepalived/haproxy/director) on each machine. Keepalived will handle 
the floating ip job, haproxies will have no problems with the floating 
ip, the directors will always be binded to the static ips of the 
machines and have their setup in the haproxies. That's all.


But, if you plan to make a Highly available environment, u have to 
consider splitting your services to different VMs, and them to different 
hypervisors in order to be as Highly available as you can


John



Re: dovecot director and keepalived

2021-03-15 Thread Robert Schetterer

Am 14.03.21 um 17:52 schrieb Steven Varco:

Hi All

I’m trying to establish a dovecot HA setup with two loadbalancers, running 
keepalived for sharing a virtual public IP.
On the same machines I’m running a dovecot director which proxies the requests 
to two underlying mail servers (on seperate machines).

Now I’m hitting the issue with the way director determines his „Self IP“ by 
trying to bind to all configured director_servers IPs, taking the first one 
possible.

However this approach only works, when the sysctl setting is: 
net.ipv4.ip_nonlocal_bind=0
On the other side keepalived needs net.ipv4.ip_nonlocal_bind=1 in order to bind 
the VIP.

The last topic on that is dating back to 2016 
(https://dovecot.org/pipermail/dovecot/2016-August/105191.html) with references 
to 2012 (https://www.dovecot.org/list/dovecot/2012-November/087033.html) and no 
solution posted so far.

After five more years :D, I’m asking myself if we finally have a solution for 
that, or if my approach of achieving clustered director servers is potentially 
wrong?

Other possible solutions I could think about:
- Configure each director as „independent“ by setting only one IP in 
director_servers.
   => With this aporach you would loose the user to mailserver mapping, 
although only in a a case of a failover on the loadbalancer, which might can be 
neglected (or are there any other fallbacks?)

- Only have director running on the currently active loadblancer node and 
stopped on the passive loadblancer node (would possibly have the same effects 
as above).

- Putting director on seperated intermediate machines and proxing the requests through 
haproxy on the keepalived servers (keepalived -> haproxy -> director -> IMAP
=> Besides the disadvantage of having another bunch of servers in the 
chain, also some special configuration on the directory servers might be 
neccessary to assure director works neatly with haproxy.


So 2021, what is the „correct“ (best practive) way of having a reduntant HA 
setup for dovecot?

This means a MUA connects to one public IP and gets connected to (preferably 
the same) IMAP Server, no matter which machine in the whole chain might be down?
PS: Using just multiple A records on the mail domain name (round-robin), while 
working perfectly for SMTP is not accepatbl for IMAP IMHO, as in case of a 
failure every second request from the client (MUA) would fail and most MUAs are 
not automatially reconnecting again in that case.

thanks,
Steven



hi ,i had this long time ago

https://blog.sys4.de/tag/keepalived.html

but dovecot has some new stuff since then, you might combinate them with 
keepalived which worked extrem good


--
[*] sys4 AG

http://sys4.de, +49 (89) 30 90 46 64
Schleißheimer Straße 26/MG, 80333 München

Sitz der Gesellschaft: München, Amtsgericht München: HRB 199263
Vorstand: Patrick Ben Koetter, Marc Schiffbauer
Aufsichtsratsvorsitzender: Florian Kirstein


RE: how to reclaim disk space mdbox

2021-03-15 Thread Marc
> When I delete messages in the archive namespace they are copied to the
> deleted items folder in the inbox namespace. This is 34MB increase is
> visible however I expected the archive to go down by 34MB.
> 
> Is diskspace reclaimed automatically or do you need to issue an command?
> 
> [@ sbin]# du -s -k /home/popusers/testtest /home/mail-archive/testtest
> 135472  /home/popusers/testtest
> 358824  /home/mail-archive/testtest
> 
> [@ sbin]# du -s -k /home/popusers/testtest /home/mail-archive/testtest
> 169368  /home/popusers/testtest
> 358824  /home/mail-archive/testtest
> 
> PS. I have mdbox_rotate_size = 4 M
> 
> 

I guess messages are being copied to the other namespace and in the source 
namespace their refcount is set to 0.

So only a doveadm -v purge -u testtest can release this I guess?


how to reclaim disk space mdbox

2021-03-15 Thread Marc

When I delete messages in the archive namespace they are copied to the deleted 
items folder in the inbox namespace. This is 34MB increase is visible however I 
expected the archive to go down by 34MB. 

Is diskspace reclaimed automatically or do you need to issue an command?

[@ sbin]# du -s -k /home/popusers/testtest /home/mail-archive/testtest
135472  /home/popusers/testtest
358824  /home/mail-archive/testtest

[@ sbin]# du -s -k /home/popusers/testtest /home/mail-archive/testtest
169368  /home/popusers/testtest
358824  /home/mail-archive/testtest

PS. I have mdbox_rotate_size = 4 M





Re: dovecot director and keepalived

2021-03-15 Thread Steven Varco
Hi John

Thanks for you input.

So you basically state that („physically“) separating the director servers from 
keepalive/haproxy servers is the only option?
I would like to avoid setting up two additional machines for that whenever 
possible, as any node more in the chain potentially is another point of 
failure… ;)

I’m curious to hear of any others how they did their dovecot IMAP HA setup, 
maybe raising som new ideas. :)

BTW: Why was never such a simple thing added to the direcotors code to .i.ex. 
just specifiy which is the IP of a director server itsels?
Example with a new configuriony option „my_director_sever“:

both directors:
-
director_servers: 192.168.1.10 192.168.1.20 
-

on director-2:
-
my_director_sever: 192.168.1.20 
-

cheers,
Steven

-- 
https://steven.varco.ch/ 


> Am 14.03.2021 um 20:14 schrieb Paterakis E. Ioannis :
> 
> On 14/3/2021 6:52 μ.μ., Steven Varco wrote:
> 
>> Hi All
>> 
>> I’m trying to establish a dovecot HA setup with two loadbalancers, running 
>> keepalived for sharing a virtual public IP.
>> On the same machines I’m running a dovecot director which proxies the 
>> requests to two underlying mail servers (on seperate machines).
>> 
>> Now I’m hitting the issue with the way director determines his „Self IP“ by 
>> trying to bind to all configured director_servers IPs, taking the first one 
>> possible.
> 
> Each Director has to listen only on the static IP address of each machine. 
> Then you have to configure the 2 directors in the HAproxies. The floating ip 
> with keepalived will work along with the 2 HAproxies.
> 
>> However this approach only works, when the sysctl setting is: 
>> net.ipv4.ip_nonlocal_bind=0
>> On the other side keepalived needs net.ipv4.ip_nonlocal_bind=1 in order to 
>> bind the VIP.
> 
> You don't have to mess with these settings.
> 
>> Other possible solutions I could think about:
>> - Configure each director as „independent“ by setting only one IP in 
>> director_servers.
>>   => With this aporach you would loose the user to mailserver mapping, 
>> although only in a a case of a failover on the loadbalancer, which might can 
>> be neglected (or are there any other fallbacks?)
> 
> The two directors have a connection to each other, so both know at the same 
> time where's a user mapped. You don't have to worry about that. The 
> user->dovecot mapping will work without any problems even if there is a 
> failover.
> 
>> - Putting director on seperated intermediate machines and proxing the 
>> requests through haproxy on the keepalived servers (keepalived -> haproxy -> 
>> director -> IMAP
>>=> Besides the disadvantage of having another bunch of servers in the 
>> chain, also some special configuration on the directory servers might be 
>> neccessary to assure director works neatly with haproxy.
> 
> The identical scenario will be to have keepalived along with haproxy on same 
> machine, and directors on another. But can work with all three on the same as 
> well. I use the keepalived, haproxy on two machines, with 2 directors 
> underneath each one on different machine/hardware for the high availability's 
> sake, and below them there are 3 dovecot servers.
> 
>> So 2021, what is the „correct“ (best practive) way of having a reduntant HA 
>> setup for dovecot?
> 
> Cheers :-)
> 
> John
> 
> 



Re: Virtual users @ virtual domains / better documentation?

2021-03-15 Thread Matt Anton
Le Tue, 09 Mar 2021 08:47:12 -0900,
justina colmena ~biz  a écrit :

> If the $virtual_alias_maps directive invalidates virtual mailboxes,
> then "the usual" aliases (postmaster@, etc.) for the virtual domains
> would have to be listed in
> /etc/aliases
> along with the non-virtual aliases, but this does not work either,
> and generates a warning when "newaliases" is run.
> 
> postalias: warning: /etc/aliases, line 99: name must be local
> 
> So as far as I can tell, no aliasing at all is available for 
> "virtual_mailbox_domains" in postfix

/etc/aliases for local alias only. Use "virtual_alias_maps =
hash:$config_directory/virtual" for virtual addresses
(left-hand) resolution to virtual and or (local addresses if need to)
(right-hand) on this table.

Then set in postfix main.cf the *_transport:
virtual_transport = lmtp:unix:private/dovecot-lmtp # this path is
relative to /var/spool/postfix/
mailbox_transport = ${virtual_transport}

> I am still unsure how to authenticate the virtual users on postfix.
> PAM authentication works fine for non-virtual users. The following
> command gives two options for authentication: cyrus-sasl and
> dovecot-sasl.
> 
> # postconf -a
> cyrus
> dovecot
> 
> Postfix also works with cyrus-sasl if the passwords are set in
> "/etc/sasldb2" via the "saslpasswd2" command, but dovecot doesn't
> seem to work with cyrus-sasl, and has its own type of sasl
> authentication.
> 
> I realize this is not a postfix list, so my real question here is,
> What do I need in order for dovecot to authenticate the virtual users
> and allow them to read their mail and obtain authorization to send
> mail via postfix on the same system?

cyrus-sasl isn't needed if you're running dovecot (dovecot does provide
an SASL authentication socket).

From postfix view, use in main.cf:
smtpd_sasl_security_options = noanymous, noactive, nodictionary
smtpd_sasl_type = dovecot
smtpd_sasl_path = private/auth # this path is relative to
/var/spool/postfix/

From dovecot view, configure a service auth:

service auth {
unix_listener /var/spool/postfix/private/auth {
  group = postfix
  mode = 0660
  user = postfix
}
}

Then for your virtual users, you'll need to maintain a virtual users
table backend (be it flat file, SQL, etc.):



-- 
matt [at] lv223.org
GPG key ID: 7D91A8CA



pgpIp2syB7yiH.pgp
Description: Signature digitale OpenPGP


Doveadm-Purge dry run

2021-03-15 Thread Marc
Maybe it is nice to introduce some option to Doveadm-Purge that does not delete 
anything just logs what it wanted to delete sort of like rsync's -n option.







RE: archive namespace reports mdbox_deleted: same as mdbox: is that ok?

2021-03-15 Thread Marc
> > > step 5.
> > > ===
> > > verify refcount=0 messages in folders, not ok, INBOX/test2 should
> have 5
> > >
> > > [@ testtest]# doveadm -o
> > >
> mail_location=mdbox_deleted:/home/popusers/testtest/mdbox:INDEX=/home/po
> > > pindex/testtest/index mailbox status -u testtest 'messages vsize'
> '*'
> > > Sent messages=0 vsize=0
> > > Drafts messages=0 vsize=0
> > > INBOX/test2 messages=0 vsize=0
> > > Junk messages=0 vsize=0
> > > Deleted Messages messages=0 vsize=0
> > > Deleted Messages/test messages=0 vsize=0
> > > Trash messages=0 vs
ize=0
> > > INBOX messages=3 vsize=90243
> > >
> >
> > This sould list this deleted emails not? If I do doveadm search -u
> testtest mailbox 'INBOX/test2' DELETED, it lists these emails.
> 
> Nope, expunged only. If they just have DELETED flag, they are not
> expunged yet.

After expunging still reporting 0. I am starting feel a bit like idiot. You 
want to have some manpage that is dedicated to deleting counting and restoring 
mail :)

[@ testtest]# doveadm expunge -u testtest mailbox 'INBOX/test2' DELETED
doveadm(testtest): Info: expunge: box=INBOX/test2, 
msgid=<202009061345.086Dj3vv026298@xxx>
doveadm(testtest): Info: expunge: box=INBOX/test2, 
msgid=<202009061345.086Dj3vv026298@xxx>
doveadm(testtest): Info: expunge: box=INBOX/test2, 
msgid=<202009061345.086Dj3vv026298@xxx>
doveadm(testtest): Info: expunge: box=INBOX/test2, 
msgid=<202009061345.086Dj3vv026298@xxx>
doveadm(testtest): Info: expunge: box=INBOX/test2, 
msgid=<202009061345.086Dj3vv026298@xxx>


[@ testtest]# doveadm -o 
mail_location=mdbox_deleted:/home/popusers/testtest/mdbox:INDEX=/home/popindex/testtest/index
 mailbox status -u testtest 'messages vsize' '*'

Sent messages=0 vsize=0
Drafts messages=0 vsize=0
INBOX/test2 messages=0 vsize=0
Junk messages=0 vsize=0
Deleted Messages messages=0 vsize=0
Deleted Messages/test messages=0 vsize=0
Trash messages=0 vsize=0
RESTORED messages=0 vsize=0
INBOX messages=0 vsize=0


RE: archive namespace reports mdbox_deleted: same as mdbox: is that ok?

2021-03-15 Thread Aki Tuomi


> On 15/03/2021 15:50 Marc  wrote:
> 
>  
> > 
> > step 5.
> > ===
> > verify refcount=0 messages in folders, not ok, INBOX/test2 should have 5
> > 
> > [@ testtest]# doveadm -o
> > mail_location=mdbox_deleted:/home/popusers/testtest/mdbox:INDEX=/home/po
> > pindex/testtest/index mailbox status -u testtest 'messages vsize' '*'
> > Sent messages=0 vsize=0
> > Drafts messages=0 vsize=0
> > INBOX/test2 messages=0 vsize=0
> > Junk messages=0 vsize=0
> > Deleted Messages messages=0 vsize=0
> > Deleted Messages/test messages=0 vsize=0
> > Trash messages=0 vsize=0
> > INBOX messages=3 vsize=90243
> > 
> 
> This sould list this deleted emails not? If I do doveadm search -u testtest 
> mailbox 'INBOX/test2' DELETED, it lists these emails.

Nope, expunged only. If they just have DELETED flag, they are not expunged yet.

Aki


RE: archive namespace reports mdbox_deleted: same as mdbox: is that ok?

2021-03-15 Thread Marc
> 
> step 5.
> ===
> verify refcount=0 messages in folders, not ok, INBOX/test2 should have 5
> 
> [@ testtest]# doveadm -o
> mail_location=mdbox_deleted:/home/popusers/testtest/mdbox:INDEX=/home/po
> pindex/testtest/index mailbox status -u testtest 'messages vsize' '*'
> Sent messages=0 vsize=0
> Drafts messages=0 vsize=0
> INBOX/test2 messages=0 vsize=0
> Junk messages=0 vsize=0
> Deleted Messages messages=0 vsize=0
> Deleted Messages/test messages=0 vsize=0
> Trash messages=0 vsize=0
> INBOX messages=3 vsize=90243
> 

This sould list this deleted emails not? If I do doveadm search -u testtest 
mailbox 'INBOX/test2' DELETED, it lists these emails.




Re: [ext] Re: What is the state of SMTPUTF8 support?

2021-03-15 Thread Sylvhem
Le dimanche 14 mars 2021 à 21:13 +0100, Benny Pedersen a écrit :
> On 2021-03-14 17:29, Ralf Hildebrandt wrote:
> > * Ralf Hildebrandt :
> > > > I didn’t get any answer. Does somebody know if there was any
> > > > progress
> > > > in implementing the RFC 6531?
> > > 
> > > http://www.postfix.org/SMTPUTF8_README.html
> > 
> > Sorry, I was on the wrong list.
> 
> is there hope to see dns server support rfc 6531 ?
> 
> how should dovecot and postfix handle both idn and eai maps, postfix
> is 
> not ready yet there, its does not matter aslong dns have yet to
> support 
> eai aswell

I’m sorry, but I’m a bit puzzled by your answer.
What is the relation between RFC 6531 and the DNS? I’m clearly no
expert, but I thought that RFC only specified an SMTP extension. How
are DNS servers concerned by that?
Anyway, Postfix already implemented SMTPUTF8. Having Dovecot do as well
would allow for mail-stack that rely on both Postfix and Dovecot to
send e-mail using addresses containing non-ASCII characters. That would
be a big progress for people who wish to use internationalized e-mail
addresses.
And the last time I asked questions about it here, people said to me it
was being worked on. Hence my question.

--
Sylvhem



Re: Latest dovecot does not work with latest MUA (thunderbird)

2021-03-15 Thread gmail



I think i found cultpir: PAM is not compiled in, now i'm compiling new 
version that has PAM in.


Marc kirjoitti 15.3.2021 klo 10.43:

I assume you are refering to incomming mail. I had sometimes similar issues 
with mbox and having sendmail deliver straight to the mbox file. When I 
switched to delivering to lmtp, I never encountered it anymore. Just put this 
lmtp inbetween.




-Original Message-
From: dovecot  On Behalf Of gmail
Sent: 14 March 2021 23:30
To: dovecot@dovecot.org
Subject: Re: Latest dovecot does not work with latest MUA (thunderbird)


Stuart Henderson kirjoitti 14.3.2021 klo 23.38:

On 2021-03-14, lja@koti  wrote:

# 2.3.7.2 (3c910f64b): /etc/dovecot/dovecot.conf

That's nowhere near the latest Dovecot.



Updated dovecot to bleeding edge, and still got same issue.

# 2.4.devel (b0f498b69): /usr/local/etc/dovecot/dovecot.conf
# OS: Linux 5.9.0-rc5 x86_64 Ubuntu 20.04.2 LTS
# Hostname: superman.sillywalk.org
auth_debug = yes
auth_debug_passwords = yes
auth_mechanisms = plain login
auth_verbose = yes
auth_verbose_passwords = plain
debug_log_path = /var/log/dovecot-debug.log
info_log_path = /var/log/dovecot-info.log
log_path = /var/log/dovecot.log
mail_debug = yes
mail_location = maildir:~/Maildir/
mbox_write_locks = fcntl
namespace inbox {
    inbox = yes
    location =
    mailbox Drafts {
      special_use = \Drafts
    }
    mailbox Junk {
      special_use = \Junk
    }
    mailbox Sent {
      special_use = \Sent
    }
    mailbox "Sent Messages" {
      special_use = \Sent
    }
    mailbox Trash {
      special_use = \Trash
    }
    prefix =
}
passdb {
    driver = pam
}
protocols = imap pop3
service auth {
    unix_listener /var/spool/postfix/private/auth {
      group = mail
      mode = 0660
      user = postfix
    }
}
ssl_cert = 

Re: Latest dovecot does not work with latest MUA (thunderbird)

2021-03-15 Thread gmail



I think i found cultpir: PAM is not compiled in, now i'm compiling new 
version that has PAM in.



Aki Tuomi kirjoitti 15.3.2021 klo 9.18:

On 15/03/2021 00:33 gmail  wrote:



  Stuart Henderson kirjoitti 14.3.2021 klo 23.38:
  > On 2021-03-14, lja@koti  wrote: >> # 2.3.7.2 (3c910f64b): 
/etc/dovecot/dovecot.conf > That's nowhere near the latest Dovecot. > >Updated dovecot to 
bleeding edge, and still got same issue.
  
  # 2.4.devel (b0f498b69): /usr/local/etc/dovecot/dovecot.conf



Some basic debug things to do:

Check your /var/log/dovecot*.log to see what happens with that folder.

Also check the filesystem if "postfix" is really delivering mail to the Sent 
folder. Although normally MUA stores sent mails.

Aki


RE: archive namespace reports mdbox_deleted: same as mdbox: is that ok?

2021-03-15 Thread Marc

Adding these steps



step 6.
===
check if we have still them message stored, ok as expected

[@ testtest]# grep 45765765870 /home/popusers/testtest/mdbox/storage/*
/home/popusers/testtest/mdbox/storage/m.893:Subject: New file uploaded 
45765765870

step 7.
===
purge mailbox with

[@ testtest]# doveadm -v purge -u testtest

step 8.
===
check if we have still them message stored,  no, ok as expected

[@ testtest]# grep 45765765870 /home/popusers/testtest/mdbox/storage/*
[@ testtest]#


RE: archive namespace reports mdbox_deleted: same as mdbox: is that ok?

2021-03-15 Thread Marc
New test

step 1. 
===
initial state inbox and deleted

[@ testtest]# doveadm -o 
mail_location=mdbox:/home/popusers/testtest/mdbox:INDEX=/home/popindex/testtest/index
 mailbox status -u testtest 'messages vsize' '*'
Sent messages=17 vsize=7473
Drafts messages=6 vsize=67170
INBOX/test2 messages=198 vsize=12552420
Junk messages=2 vsize=1969
Deleted Messages messages=0 vsize=0
Trash messages=47 vsize=769284
INBOX messages=1117 vsize=207623033

[@ testtest]# doveadm -o 
mail_location=mdbox_deleted:/home/popusers/testtest/mdbox:INDEX=/home/popindex/testtest/index
 mailbox status -u testtest 'messages vsize' '*'
Sent messages=0 vsize=0
Drafts messages=0 vsize=0
INBOX/test2 messages=0 vsize=0
Junk messages=0 vsize=0
Deleted Messages messages=0 vsize=0
Trash messages=0 vsize=0
INBOX messages=2 vsize=89284

step 2.
===
check if we have messages indeed stored

[@ testtest]# grep 45765765870 /home/popusers/testtest/mdbox/storage/*
/home/popusers/testtest/mdbox/storage/m.893:Subject: New file uploaded 
45765765870


step 3. 
===
delete 5 messages including the one having subject '45765765870' from 
inbox/test2 mailbox with thunderbird shift+delete, restart thunderbird 
(otherwise nothing happens on server)

step 4. 
===
verify if messages are indeed deleted, looks like ok, indeed 5 fewer messages.

[@ testtest]# doveadm -o 
mail_location=mdbox:/home/popusers/testtest/mdbox:INDEX=/home/popindex/testtest/index
 mailbox status -u testtest 'messages vsize' '*'
Sent messages=17 vsize=7473
Drafts messages=6 vsize=67170
INBOX/test2 messages=193 vsize=12296609
Junk messages=2 vsize=1969
Deleted Messages messages=0 vsize=0
Trash messages=47 vsize=769284
INBOX messages=1117 vsize=207623033

step 5.
===
verify refcount=0 messages in folders, not ok, INBOX/test2 should have 5

[@ testtest]# doveadm -o 
mail_location=mdbox_deleted:/home/popusers/testtest/mdbox:INDEX=/home/popindex/testtest/index
 mailbox status -u testtest 'messages vsize' '*'
Sent messages=0 vsize=0
Drafts messages=0 vsize=0
INBOX/test2 messages=0 vsize=0
Junk messages=0 vsize=0
Deleted Messages messages=0 vsize=0
Deleted Messages/test messages=0 vsize=0
Trash messages=0 vsize=0
INBOX messages=3 vsize=90243







RE: archive namespace reports mdbox_deleted: same as mdbox: is that ok?

2021-03-15 Thread Aki Tuomi


> On 15/03/2021 13:56 Marc  wrote:
> 
>  
> Sorry Aki for asking again. I need to run the purge, but I want to make sure 
> some user did not accedentally deleted a large folder.
> 
> I decided to keep tests limited for now to the main inbox namespace. But also 
> here weird results.
> 
> Status of folders before the test[1], selected 10 messages from INBOX/test2 
> and shift+deleted them. Then restarted thunderbird (otherwise thunderbird 
> kept showing 211 messages), INBOX/test2 indeed shows 10 fewer messages, now 
> 201, but no deleted messages found INBOX/test2 and weirdly 1 in INBOX??? 
> (result is the same after a force-resync)
> 
> If this surpasses public support let me know.
> 
> 
> [1]
> [@ testtest]# doveadm -v purge -u testtest
> 
> [@ testtest]# doveadm -o 
> mail_location=mdbox:/home/popusers/testtest/mdbox:INDEX=/home/popindex/testtest/index
>  mailbox status -u testtest 'messages vsize' '*'
> Sent messages=17 vsize=7473
> Drafts messages=6 vsize=91785
> INBOX/test2 messages=211 vsize=13443443
> Junk messages=2 vsize=1969
> Deleted Messages messages=1 vsize=956
> Trash messages=47 vsize=769284
> INBOX messages=1117 vsize=207623033
> 
> [@ testtest]# doveadm -o 
> mail_location=mdbox_deleted:/home/popusers/testtest/mdbox:INDEX=/home/popindex/testtest/index
>  mailbox status -u testtest 'messages vsize' '*'
> Sent messages=0 vsize=0
> Drafts messages=0 vsize=0
> INBOX/test2 messages=0 vsize=0
> Junk messages=0 vsize=0
> Deleted Messages messages=0 vsize=0
> Trash messages=0 vsize=0
> INBOX messages=0 vsize=0
> 
> [2]
> [@ testtest]# doveadm -o 
> mail_location=mdbox:/home/popusers/testtest/mdbox:INDEX=/home/popindex/testtest/index
>  mailbox status -u testtest 'messages vsize' '*'
> Sent messages=17 vsize=7473
> Drafts messages=5 vsize=3457
> INBOX/test2 messages=201 vsize=12806313
> Junk messages=2 vsize=1969
> Deleted Messages messages=1 vsize=956
> Trash messages=47 vsize=769284
> INBOX messages=1117 vsize=207623033
> 
> [@ testtest]# doveadm -o 
> mail_location=mdbox_deleted:/home/popusers/testtest/mdbox:INDEX=/home/popindex/testtest/index
>  mailbox status -u testtest 'messages vsize' '*'
> Sent messages=0 vsize=0
> Drafts messages=0 vsize=0
> INBOX/test2 messages=0 vsize=0
> Junk messages=0 vsize=0
> Deleted Messages messages=0 vsize=0
> Trash messages=0 vsize=0
> INBOX messages=1 vsize=88328
> 
> 
> [3]
> [@]# doveconf | grep mail_location
> mail_location = 
> mdbox:~/mdbox:INDEX=/home/popindex/%u/index:CONTROL=~/mail/control

Can you please be more specific about the steps you've taken and provide some 
steps how you did this testing including deleting mails and such? Now it's bit 
random and hard to track.

Aki


RE: archive namespace reports mdbox_deleted: same as mdbox: is that ok?

2021-03-15 Thread Marc

Sorry Aki for asking again. I need to run the purge, but I want to make sure 
some user did not accedentally deleted a large folder.

I decided to keep tests limited for now to the main inbox namespace. But also 
here weird results.

Status of folders before the test[1], selected 10 messages from INBOX/test2 and 
shift+deleted them. Then restarted thunderbird (otherwise thunderbird kept 
showing 211 messages), INBOX/test2 indeed shows 10 fewer messages, now 201, but 
no deleted messages found INBOX/test2 and weirdly 1 in INBOX??? (result is the 
same after a force-resync)

If this surpasses public support let me know.


[1]
[@ testtest]# doveadm -v purge -u testtest

[@ testtest]# doveadm -o 
mail_location=mdbox:/home/popusers/testtest/mdbox:INDEX=/home/popindex/testtest/index
 mailbox status -u testtest 'messages vsize' '*'
Sent messages=17 vsize=7473
Drafts messages=6 vsize=91785
INBOX/test2 messages=211 vsize=13443443
Junk messages=2 vsize=1969
Deleted Messages messages=1 vsize=956
Trash messages=47 vsize=769284
INBOX messages=1117 vsize=207623033

[@ testtest]# doveadm -o 
mail_location=mdbox_deleted:/home/popusers/testtest/mdbox:INDEX=/home/popindex/testtest/index
 mailbox status -u testtest 'messages vsize' '*'
Sent messages=0 vsize=0
Drafts messages=0 vsize=0
INBOX/test2 messages=0 vsize=0
Junk messages=0 vsize=0
Deleted Messages messages=0 vsize=0
Trash messages=0 vsize=0
INBOX messages=0 vsize=0

[2]
[@ testtest]# doveadm -o 
mail_location=mdbox:/home/popusers/testtest/mdbox:INDEX=/home/popindex/testtest/index
 mailbox status -u testtest 'messages vsize' '*'
Sent messages=17 vsize=7473
Drafts messages=5 vsize=3457
INBOX/test2 messages=201 vsize=12806313
Junk messages=2 vsize=1969
Deleted Messages messages=1 vsize=956
Trash messages=47 vsize=769284
INBOX messages=1117 vsize=207623033

[@ testtest]# doveadm -o 
mail_location=mdbox_deleted:/home/popusers/testtest/mdbox:INDEX=/home/popindex/testtest/index
 mailbox status -u testtest 'messages vsize' '*'
Sent messages=0 vsize=0
Drafts messages=0 vsize=0
INBOX/test2 messages=0 vsize=0
Junk messages=0 vsize=0
Deleted Messages messages=0 vsize=0
Trash messages=0 vsize=0
INBOX messages=1 vsize=88328


[3]
[@]# doveconf | grep mail_location
mail_location = 
mdbox:~/mdbox:INDEX=/home/popindex/%u/index:CONTROL=~/mail/control


RE: archive namespace reports mdbox_deleted: same as mdbox: is that ok?

2021-03-15 Thread Marc
Hmmm, terribly sorry, I think it is related to that Archive is stored in 


[@]# doveconf | grep  location
mail_location = 
mdbox:~/mdbox:INDEX=/home/popindex/%u/index:CONTROL=~/mail/control
  location = 
mdbox:/home/mail-archive/%u/Archive/:CONTROL=/home/mail-archive/%u/Archive/control:INDEX=/home/archiveindex/%u/index
  location =


> -Original Message-
> From: Aki Tuomi 
> Sent: 15 March 2021 11:24
> To: Marc ; dovecot@dovecot.org
> Subject: RE: archive namespace reports mdbox_deleted: same as mdbox: is
> that ok?
> 
> 
> > On 15/03/2021 12:12 Marc  wrote:
> >
> >
> > I am not sure if you wanted me to just add another -o, so I did these
> 3, but all with same results[1].
> >
> >
> >
> >
> 
> That's because you did it slightly wrong..
> 
> doveadm -D -o namespace/4archives/location=mdbox_deleted:/home/mail-
> archive/testtest/Archive/:CONTROL=/home/mail-
> archive/testtest/Archive/control:INDEX=/home/archiveindex/testtest/index
> -o testtest 'messages vsize' "Archive/2018"
> 
> Aki


RE: archive namespace reports mdbox_deleted: same as mdbox: is that ok?

2021-03-15 Thread Aki Tuomi


> On 15/03/2021 12:12 Marc  wrote:
> 
>  
> I am not sure if you wanted me to just add another -o, so I did these 3, but 
> all with same results[1].
> 
> 
> 
> 

That's because you did it slightly wrong..

doveadm -D -o 
namespace/4archives/location=mdbox_deleted:/home/mail-archive/testtest/Archive/:CONTROL=/home/mail-archive/testtest/Archive/control:INDEX=/home/archiveindex/testtest/index
 -o testtest 'messages vsize' "Archive/2018"

Aki


RE: archive namespace reports mdbox_deleted: same as mdbox: is that ok?

2021-03-15 Thread Marc


I am not sure if you wanted me to just add another -o, so I did these 3, but 
all with same results[1].




[1]
[@ storage]# doveadm -D -o 
namespace/4archives/location=mdbox_deleted:/home/mail-archive/testtest/mdbox -o 
mail_location=mdbox_deleted:/home/mail-archive/testtest/mdbox:INDEX=/home/archiveindex/testtest/index
 mailbox status -u testtest 'messages vsize' "Archive/2018"
Debug: Loading modules from directory: /usr/lib64/dovecot
Debug: Module loaded: /usr/lib64/dovecot/lib15_notify_plugin.so
Debug: Module loaded: /usr/lib64/dovecot/lib20_mail_log_plugin.so
Debug: Module loaded: /usr/lib64/dovecot/lib20_replication_plugin.so
Debug: Module loaded: /usr/lib64/dovecot/lib90_stats_plugin.so
Debug: Loading modules from directory: /usr/lib64/dovecot/doveadm
Debug: Skipping module doveadm_acl_plugin, because dlopen() failed: 
/usr/lib64/dovecot/doveadm/lib10_doveadm_acl_plugin.so: undefined symbol: 
acl_user_module (this is usually intentional, so just ignore this message)
Debug: Skipping module doveadm_expire_plugin, because dlopen() failed: 
/usr/lib64/dovecot/doveadm/lib10_doveadm_expire_plugin.so: undefined symbol: 
expire_set_deinit (this is usually intentional, so just ignore this message)
Debug: Skipping module doveadm_quota_plugin, because dlopen() failed: 
/usr/lib64/dovecot/doveadm/lib10_doveadm_quota_plugin.so: undefined symbol: 
quota_user_module (this is usually intentional, so just ignore this message)
Debug: Module loaded: /usr/lib64/dovecot/doveadm/lib10_doveadm_sieve_plugin.so
Debug: Skipping module doveadm_fts_lucene_plugin, because dlopen() failed: 
/usr/lib64/dovecot/doveadm/lib20_doveadm_fts_lucene_plugin.so: undefined 
symbol: lucene_index_iter_deinit (this is usually intentional, so just ignore 
this message)
Debug: Skipping module doveadm_fts_plugin, because dlopen() failed: 
/usr/lib64/dovecot/doveadm/lib20_doveadm_fts_plugin.so: undefined symbol: 
fts_user_get_language_list (this is usually intentional, so just ignore this 
message)
Debug: Skipping module doveadm_mail_crypt_plugin, because dlopen() failed: 
/usr/lib64/dovecot/doveadm/libdoveadm_mail_crypt_plugin.so: undefined symbol: 
mail_crypt_box_get_pvt_digests (this is usually intentional, so just ignore 
this message)
doveadm(testtest): Debug: Effective uid=8267, gid=231, 
home=/home/popusers/testtest
doveadm(testtest): Debug: replication: No mail_replica setting - replication 
disabled
doveadm(testtest): Debug: Namespace inbox: type=private, prefix=, sep=/, 
inbox=yes, hidden=no, list=yes, subscriptions=yes 
location=mdbox_deleted:/home/mail-archive/testtest/mdbox:INDEX=/home/archiveindex/testtest/index
doveadm(testtest): Debug: fs: root=/home/mail-archive/testtest/mdbox, 
index=/home/archiveindex/testtest/index, indexpvt=, control=, inbox=, alt=
doveadm(testtest): Debug: Namespace 4archives: type=private, prefix=Archive/, 
sep=/, inbox=no, hidden=no, list=yes, subscriptions=yes 
location=mdbox_deleted:/home/mail-archive/testtest/mdbox
doveadm(testtest): Debug: fs: root=/home/mail-archive/testtest/mdbox, index=, 
indexpvt=, control=, inbox=, alt=
doveadm(testtest): Debug: Archive/2018: Mailbox opened because: mailbox status
doveadm(testtest): Error: Mailbox Archive/2018: Failed to lookup mailbox 
status: Mailbox doesn't exist: Archive/2018

[@ storage]# doveadm -D -o 
namespace/4archives/location=mdbox_deleted:/home/mail-archive/testtest/mdbox:INDEX=/home/archiveindex/testtest/index
 mailbox status -u testtest 'messages vsize' "Archive/2018"
Debug: Loading modules from directory: /usr/lib64/dovecot
Debug: Module loaded: /usr/lib64/dovecot/lib15_notify_plugin.so
Debug: Module loaded: /usr/lib64/dovecot/lib20_mail_log_plugin.so
Debug: Module loaded: /usr/lib64/dovecot/lib20_replication_plugin.so
Debug: Module loaded: /usr/lib64/dovecot/lib90_stats_plugin.so
Debug: Loading modules from directory: /usr/lib64/dovecot/doveadm
Debug: Skipping module doveadm_acl_plugin, because dlopen() failed: 
/usr/lib64/dovecot/doveadm/lib10_doveadm_acl_plugin.so: undefined symbol: 
acl_user_module (this is usually intentional, so just ignore this message)
Debug: Skipping module doveadm_expire_plugin, because dlopen() failed: 
/usr/lib64/dovecot/doveadm/lib10_doveadm_expire_plugin.so: undefined symbol: 
expire_set_deinit (this is usually intentional, so just ignore this message)
Debug: Skipping module doveadm_quota_plugin, because dlopen() failed: 
/usr/lib64/dovecot/doveadm/lib10_doveadm_quota_plugin.so: undefined symbol: 
quota_user_module (this is usually intentional, so just ignore this message)
Debug: Module loaded: /usr/lib64/dovecot/doveadm/lib10_doveadm_sieve_plugin.so
Debug: Skipping module doveadm_fts_lucene_plugin, because dlopen() failed: 
/usr/lib64/dovecot/doveadm/lib20_doveadm_fts_lucene_plugin.so: undefined 
symbol: lucene_index_iter_deinit (this is usually intentional, so just ignore 
this message)
Debug: Skipping module doveadm_fts_plugin, because dlopen() failed: 
/usr/lib64/dovecot/doveadm/lib20_doveadm_fts_plugin.so: 

RE: archive namespace reports mdbox_deleted: same as mdbox: is that ok?

2021-03-15 Thread Aki Tuomi


> On 15/03/2021 11:43 Marc  wrote:
> 
>  
> [@ ~]# doveadm -D -o 
> mail_location=mdbox_deleted:/home/mail-archive/testtest/mdbox:INDEX=/home/archiveindex/testtest/index
>  mailbox status -u testtest 'messages vsize' "Archive/2018"
> 
> doveadm(testtest): Debug: Namespace 4archives: type=private, prefix=Archive/, 
> sep=/, inbox=no, hidden=no, list=yes, subscriptions=yes 
> location=mdbox:/home/mail-archive/testtest/Archive/:CONTROL=/home/mail-archive/testtest/Archive/control:INDEX=/home/archiveindex/testtest/index
> doveadm(testtest): Debug: fs: root=/home/mail-archive/testtest/Archive, 
> index=/home/archiveindex/testtest/index, indexpvt=, 
> control=/home/mail-archive/testtest/Archive/control, inbox=, alt=
> doveadm(testtest): Debug: Archive/2018: Mailbox opened because: mailbox status
> Archive/2018 messages=70 vsize=6182960

Try `doveadm -o namespace/4archives/location=mdbox_deleted:.../ mailbox status 
...`

Aki


RE: archive namespace reports mdbox_deleted: same as mdbox: is that ok?

2021-03-15 Thread Marc


[@ ~]# doveadm -D -o 
mail_location=mdbox_deleted:/home/mail-archive/testtest/mdbox:INDEX=/home/archiveindex/testtest/index
 mailbox status -u testtest 'messages vsize' "Archive/2018"

Debug: Loading modules from directory: /usr/lib64/dovecot
Debug: Module loaded: /usr/lib64/dovecot/lib15_notify_plugin.so
Debug: Module loaded: /usr/lib64/dovecot/lib20_mail_log_plugin.so
Debug: Module loaded: /usr/lib64/dovecot/lib20_replication_plugin.so
Debug: Module loaded: /usr/lib64/dovecot/lib90_stats_plugin.so
Debug: Loading modules from directory: /usr/lib64/dovecot/doveadm
Debug: Skipping module doveadm_acl_plugin, because dlopen() failed: 
/usr/lib64/dovecot/doveadm/lib10_doveadm_acl_plugin.so: undefined symbol: 
acl_user_module (this is usually intentional, so just ignore this message)
Debug: Skipping module doveadm_expire_plugin, because dlopen() failed: 
/usr/lib64/dovecot/doveadm/lib10_doveadm_expire_plugin.so: undefined symbol: 
expire_set_deinit (this is usually intentional, so just ignore this message)
Debug: Skipping module doveadm_quota_plugin, because dlopen() failed: 
/usr/lib64/dovecot/doveadm/lib10_doveadm_quota_plugin.so: undefined symbol: 
quota_user_module (this is usually intentional, so just ignore this message)
Debug: Module loaded: /usr/lib64/dovecot/doveadm/lib10_doveadm_sieve_plugin.so
Debug: Skipping module doveadm_fts_lucene_plugin, because dlopen() failed: 
/usr/lib64/dovecot/doveadm/lib20_doveadm_fts_lucene_plugin.so: undefined 
symbol: lucene_index_iter_deinit (this is usually intentional, so just ignore 
this message)
Debug: Skipping module doveadm_fts_plugin, because dlopen() failed: 
/usr/lib64/dovecot/doveadm/lib20_doveadm_fts_plugin.so: undefined symbol: 
fts_user_get_language_list (this is usually intentional, so just ignore this 
message)
Debug: Skipping module doveadm_mail_crypt_plugin, because dlopen() failed: 
/usr/lib64/dovecot/doveadm/libdoveadm_mail_crypt_plugin.so: undefined symbol: 
mail_crypt_box_get_pvt_digests (this is usually intentional, so just ignore 
this message)
doveadm(testtest): Debug: Effective uid=8267, gid=231, 
home=/home/popusers/testtest
doveadm(testtest): Debug: replication: No mail_replica setting - replication 
disabled
doveadm(testtest): Debug: Namespace inbox: type=private, prefix=, sep=/, 
inbox=yes, hidden=no, list=yes, subscriptions=yes 
location=mdbox_deleted:/home/mail-archive/testtest/mdbox:INDEX=/home/archiveindex/testtest/index
doveadm(testtest): Debug: fs: root=/home/mail-archive/testtest/mdbox, 
index=/home/archiveindex/testtest/index, indexpvt=, control=, inbox=, alt=
doveadm(testtest): Debug: Namespace 4archives: type=private, prefix=Archive/, 
sep=/, inbox=no, hidden=no, list=yes, subscriptions=yes 
location=mdbox:/home/mail-archive/testtest/Archive/:CONTROL=/home/mail-archive/testtest/Archive/control:INDEX=/home/archiveindex/testtest/index
doveadm(testtest): Debug: fs: root=/home/mail-archive/testtest/Archive, 
index=/home/archiveindex/testtest/index, indexpvt=, 
control=/home/mail-archive/testtest/Archive/control, inbox=, alt=
doveadm(testtest): Debug: Archive/2018: Mailbox opened because: mailbox status
Archive/2018 messages=70 vsize=6182960





[@ ~]# doveadm -D -o 
mail_location=mdbox:/home/mail-archive/testtest/mdbox:INDEX=/home/archiveindex/testtest/index
 mailbox status -u testtest 'messages vsize' "Archive/2018"

Debug: Loading modules from directory: /usr/lib64/dovecot
Debug: Module loaded: /usr/lib64/dovecot/lib15_notify_plugin.so
Debug: Module loaded: /usr/lib64/dovecot/lib20_mail_log_plugin.so
Debug: Module loaded: /usr/lib64/dovecot/lib20_replication_plugin.so
Debug: Module loaded: /usr/lib64/dovecot/lib90_stats_plugin.so
Debug: Loading modules from directory: /usr/lib64/dovecot/doveadm
Debug: Skipping module doveadm_acl_plugin, because dlopen() failed: 
/usr/lib64/dovecot/doveadm/lib10_doveadm_acl_plugin.so: undefined symbol: 
acl_user_module (this is usually intentional, so just ignore this message)
Debug: Skipping module doveadm_expire_plugin, because dlopen() failed: 
/usr/lib64/dovecot/doveadm/lib10_doveadm_expire_plugin.so: undefined symbol: 
expire_set_deinit (this is usually intentional, so just ignore this message)
Debug: Skipping module doveadm_quota_plugin, because dlopen() failed: 
/usr/lib64/dovecot/doveadm/lib10_doveadm_quota_plugin.so: undefined symbol: 
quota_user_module (this is usually intentional, so just ignore this message)
Debug: Module loaded: /usr/lib64/dovecot/doveadm/lib10_doveadm_sieve_plugin.so
Debug: Skipping module doveadm_fts_lucene_plugin, because dlopen() failed: 
/usr/lib64/dovecot/doveadm/lib20_doveadm_fts_lucene_plugin.so: undefined 
symbol: lucene_index_iter_deinit (this is usually intentional, so just ignore 
this message)
Debug: Skipping module doveadm_fts_plugin, because dlopen() failed: 
/usr/lib64/dovecot/doveadm/lib20_doveadm_fts_plugin.so: undefined symbol: 
fts_user_get_language_list (this is usually intentional, so just ignore this 
message)
Debug: Skipping module 

Re: archive namespace reports mdbox_deleted: same as mdbox: is that ok?

2021-03-15 Thread Aki Tuomi
> On 15/03/2021 11:23 Marc  wrote:
> 
>  
> These commands should generate different output not?
> 
> [@ ~]# doveadm -o 
> mail_location=mdbox_deleted:/home/mail-archive/testtest/mdbox:INDEX=/home/archiveindex/testtest/index
>  mailbox status -u testtest 'messages vsize' "Archive/2018"
> 
> Archive/2018 messages=70 vsize=6182960
> 
> [@ ~]# doveadm -o 
> mail_location=mdbox:/home/mail-archive/testtest/mdbox:INDEX=/home/archiveindex/testtest/index
>  mailbox status -u testtest 'messages vsize' "Archive/2018"
> 
> Archive/2018 messages=70 vsize=6182960

Can you try that again with

doveadm -D

Aki


archive namespace reports mdbox_deleted: same as mdbox: is that ok?

2021-03-15 Thread Marc

These commands should generate different output not?

[@ ~]# doveadm -o 
mail_location=mdbox_deleted:/home/mail-archive/testtest/mdbox:INDEX=/home/archiveindex/testtest/index
 mailbox status -u testtest 'messages vsize' "Archive/2018"

Archive/2018 messages=70 vsize=6182960

[@ ~]# doveadm -o 
mail_location=mdbox:/home/mail-archive/testtest/mdbox:INDEX=/home/archiveindex/testtest/index
 mailbox status -u testtest 'messages vsize' "Archive/2018"

Archive/2018 messages=70 vsize=6182960









RE: Latest dovecot does not work with latest MUA (thunderbird)

2021-03-15 Thread Marc
I assume you are refering to incomming mail. I had sometimes similar issues 
with mbox and having sendmail deliver straight to the mbox file. When I 
switched to delivering to lmtp, I never encountered it anymore. Just put this 
lmtp inbetween.



> -Original Message-
> From: dovecot  On Behalf Of gmail
> Sent: 14 March 2021 23:30
> To: dovecot@dovecot.org
> Subject: Re: Latest dovecot does not work with latest MUA (thunderbird)
> 
> 
> Stuart Henderson kirjoitti 14.3.2021 klo 23.38:
> > On 2021-03-14, lja@koti  wrote:
> >> # 2.3.7.2 (3c910f64b): /etc/dovecot/dovecot.conf
> > That's nowhere near the latest Dovecot.
> >
> >
> Updated dovecot to bleeding edge, and still got same issue.
> 
> # 2.4.devel (b0f498b69): /usr/local/etc/dovecot/dovecot.conf
> # OS: Linux 5.9.0-rc5 x86_64 Ubuntu 20.04.2 LTS
> # Hostname: superman.sillywalk.org
> auth_debug = yes
> auth_debug_passwords = yes
> auth_mechanisms = plain login
> auth_verbose = yes
> auth_verbose_passwords = plain
> debug_log_path = /var/log/dovecot-debug.log
> info_log_path = /var/log/dovecot-info.log
> log_path = /var/log/dovecot.log
> mail_debug = yes
> mail_location = maildir:~/Maildir/
> mbox_write_locks = fcntl
> namespace inbox {
>    inbox = yes
>    location =
>    mailbox Drafts {
>      special_use = \Drafts
>    }
>    mailbox Junk {
>      special_use = \Junk
>    }
>    mailbox Sent {
>      special_use = \Sent
>    }
>    mailbox "Sent Messages" {
>      special_use = \Sent
>    }
>    mailbox Trash {
>      special_use = \Trash
>    }
>    prefix =
> }
> passdb {
>    driver = pam
> }
> protocols = imap pop3
> service auth {
>    unix_listener /var/spool/postfix/private/auth {
>      group = mail
>      mode = 0660
>      user = postfix
>    }
> }
> ssl_cert =  ssl_key = # hidden, use -P to show it
> userdb {
>    driver = passwd
> }
> protocol imap {
>    imap_metadata = yes
> }
> local_name businessdomain.fi {
>    ssl_cert =     ssl_key = # hidden, use -P to show it
> }
> local_name businessdomain.com {
>    ssl_cert =     ssl_key = # hidden, use -P to show it
> }
> local_name maindomain.fi {
>    ssl_cert =     ssl_key = # hidden, use -P to show it
> }



Re: Latest dovecot does not work with latest MUA (thunderbird)

2021-03-15 Thread Aki Tuomi


> On 15/03/2021 00:33 gmail  wrote:
> 
> 
> 
>  Stuart Henderson kirjoitti 14.3.2021 klo 23.38:
>  > On 2021-03-14, lja@koti  wrote: >> # 2.3.7.2 (3c910f64b): 
> /etc/dovecot/dovecot.conf > That's nowhere near the latest Dovecot. > 
> >Updated dovecot to bleeding edge, and still got same issue.
>  
>  # 2.4.devel (b0f498b69): /usr/local/etc/dovecot/dovecot.conf
>

Some basic debug things to do:

Check your /var/log/dovecot*.log to see what happens with that folder.

Also check the filesystem if "postfix" is really delivering mail to the Sent 
folder. Although normally MUA stores sent mails.

Aki