Re: Looking for a guide to collect all e-mail from the ISP mail server

2020-10-26 Thread Filip Hajný
> 26. 10. 2020 v 15:12, R. Diez :
> 
> Thanks for the hint. I initially discarded Mailcow because of this:
> 
> "mailcow: dockerized comes with multiple containers"
> 
> The installation instructions mention that Docker Compose is required. Not 
> long ago I learnt enough to launch one Docker container. I could be convinced 
> to use a dockerised application, but multiple containers and Docker Compose? 
> I have a feeling that Mailcow is not really designed to run on premises in a 
> small business or a volunteer-based club or charity.

Not sure I understand, you don’t have to be a rocket scientist to run 
docker-compose (unlike Kubernetes maybe). I’m running it on a €5/mo 4G VM with 
Hetzner (plus some storage). It would run on just about any server you might 
have running in your office or your attic at home, and the guys have it all 
scripted up with a fancy GUI.

-F

Re: Looking for a guide to collect all e-mail from the ISP mail server

2020-10-26 Thread Filip Hajný
26. 10. 2020 v 12:15, R. Diez :
> 
> I would be happy to take a pre-packaged mail server solution like iRedMail 
> which includes RoundCube or whatever.

Have a look at Mailcow too, it comes with almost everything. I’ve been running 
it for a year now, after many years of using a self-assembled stack, and it’s a 
bliss.

I have it coupled with Amazon SES for some domains that run mailing lists. 
That’s a cheap option if you want to offload the sender reputation problem to 
someone else.

-F

Re: Changing IMAP separator - does it break things?

2020-10-14 Thread Filip Hajný
14. 10. 2020 v 13:39, Sami Ketola :
> 
>> On 14. Oct 2020, at 14.20, @lbutlr  wrote:
>> 
>> On 14 Oct 2020, at 04:24, Sami Ketola  wrote:
>>> On 14. Oct 2020, at 12.51, Victor Sudakov  wrote:
 Those Mac clients who do not use nested folders do not seem to be
 affected. That is, I've already suggested to the Mac Mail user that he
 start Thunderbird, move all his mailboxes into the IMAP root folder, and
 then go on using Mac Mail. I hope that's what he has done.
>> 
>>> There is a bug in Mail.app that it always assumes / as hierarchy separator 
>>> and 
>>> completely ignores server provided separator.
>> 
>> Cite? Because no, that is not my experience at all.
>> 
>> From my maildir on my FreeBSD server:
>> 
>> # ls -lnd .root*
>> drwx--  5 89  89  512 Oct 14 05:16 .root
>> drwx--  5 89  89  512 Oct 14 02:02 .root.44
>> drwx--  5 89  89  512 Oct 14 02:02 .root.Cron
>> drwx--  5 89  89  512 Oct 14 05:16 .root.Hastur
>> … etc
>> 
>> Works fine in Mail.app on Mac OS and has for at least 16 years.
> 
> I just tested it with my Dovecot 2.2.36 setup. I did set up an account with 
> '.' as separator and created some folders.
> First mail.app succeeded in creating test root folder but when I tried to 
> create subfolder 'test2' under 'test' Mail.app issued
> CREATE "test/test2" folder instead of "test.test2". And then failed to list 
> the created folder completely.
> 
> Everything worked if I did set separator to '/'

In my case, having the hierarchy separator set to '/', subfolders created using 
the Mail client in macOS Catalina resulted in '.folder\2esubfolder‘ on disk (2e 
corresponds to '.‘). I had to change the hierarchy separator to a dot.

So exactly the opposite!

-F

Re: Changing IMAP separator - does it break things?

2020-10-14 Thread Filip Hajný
14. 10. 2020 v 12:24, Sami Ketola :
> 
>> On 14. Oct 2020, at 12.51, Victor Sudakov  wrote:
>> 
>> Those Mac clients who do not use nested folders do not seem to be
>> affected. That is, I've already suggested to the Mac Mail user that he
>> start Thunderbird, move all his mailboxes into the IMAP root folder, and
>> then go on using Mac Mail. I hope that's what he has done.
> 
> There is a bug in Mail.app that it always assumes / as hierarchy separator 
> and 
> completely ignores server provided separator.
> 
> Not sure if anyone has created BUG to Apple about this. Atleast I have not.
> 
> Sami
> 

So hm, I actually re-read the original post, and this is pretty weird, because 
I had to change the Dovecot separator from '/' to '.' in order to make macOS 
clients work with subfolders properly.

I never had this problem myself because only use folders, not subfolders. And 
it was pointed to me by another user, who relies on subfolders and had problems 
for some time - *maybe* from since around the time she upgraded to Catalina.

-F

Re: Changing IMAP separator - does it break things?

2020-10-14 Thread Filip Hajný
14. 10. 2020 v 11:51, Victor Sudakov :
> 
>> I had to do it with 10-20 live users and it went fine, nobody noticed
>> anything (I made the change in the night hours just to be sure
>> though). I had to go down and fix some erratic folder names that
>> resulted from the botched separator handling on some macOS Mail
>> accounts.
> 
> Did it change anything on Dovecot disk/storage or is the IMAP separator just
> "virtual" - ephemeral ?

Changing the separator won't fix anything that already exists. You should see 
nonsense folders in the form of  '.folder\2esubfolder‘ there that cannot be 
worked with in any way. I manually moved the contents of these to their 
properly named ('.folder.subfolder‘) variants - on disk.

-F

Re: Changing IMAP separator - does it break things?

2020-10-14 Thread Filip Hajný
14. 10. 2020 v 11:28, Markus Winkler :
> 
> Hi Victor,
> 
> On 14.10.20 04:36, Victor Sudakov wrote:
>> Do you think I can change the hierarchy separator in the "inbox"
>> namespace without breaking other clients and the mail layout on disk,
>> losing mail etc?
> 
> I personally would try to avoid such a change (really IMHO), especially if 
> it's "only":
> 
>> I don't want to break mail for 50 people just to please one Mac Mail
>> user.
> 
> _one_ user. Could Thunderbird or another IMAP client be an option for this 
> single user? And perhaps Apple can tell some details when their Mail client 
> will be standards-compliant?
> 
> Besides that: changing the hierarchy separator is generally possible. But you 
> schould try and check that with a test system to prevent problems with your 
> productive environment and all the other users.
> 

I had to do it with 10-20 live users and it went fine, nobody noticed anything 
(I made the change in the night hours just to be sure though). I had to go down 
and fix some erratic folder names that resulted from the botched separator 
handling on some macOS Mail accounts.

The funny thing is that I set up a vanilla Dovecot server elsewhere and 
subfolders worked fine there on the very same macOS client. Couldn’t find any 
significant difference in the configs that would explain the problem, also the 
relative lack of similar reports out there seemed mind boggling.

(I’m using the Dovecot-based Mailcow mail stack for production, which makes 
troubleshooting a little more challenging.)

-F



Re: Apple Mail and subfolders

2020-07-11 Thread Filip Hajný
> I just created a subfolder in Apple mail. It shows up on the server as 
> .list.Subfolder
> I drug your message into the folder, and the message shows up in Mail.app and 
> shows up in the subfolder on the server
> 
> # ls -lnR .lists.Subfolder  [10:40] 
> [/usr/local/virtual/krem...@kreme.com/Maildir]
> total 56
> drwx--  2 89  89   512 Jul 11 10:41 cur
> -rw---  1 89  8921 Jul 11 10:41 dovecot-keywords
> -rw---  1 89  89   109 Jul 11 10:41 dovecot-uidlist
> -rw---  1 89  89  1924 Jul 11 10:41 dovecot.index.cache
> -rw---  1 89  89   868 Jul 11 10:41 dovecot.index.log
> -rw---  1 89  89 0 Jul 11 10:35 maildirfolder
> drwx--  2 89  89   512 Jul 11 10:35 new
> drwx--  2 89  89   512 Jul 11 10:41 tmp
> 

I’ve created a test server and found out that the driving factor is what the 
namespace `separator` is set to. If set to /, Apple Mail gets confused and 
URL-encodes it when creating a new folder. If the separator is blank (as set by 
default) or set to e.g. a dot, everything works just fine.

Based on example and docs I found, a slash character should be good or even 
recommended, suggesting this is some kind of bug in Apple Mail,  but I’m not 
versed enough in the IMAP related RFCs to understand.

>> 
>> This definitely used to work fine in the past.
>> 
>> Running 2.3.10.1 as part of the Mailcow suite.
> 
> I'm not familiar with that. Is that running dovecot on your Mac? My server is 
> a FreeBSD 12.1 machine running dovecot-2.3.10.1_2.

Mailcow is a suite of server SW based on Dovecot & Postfix, intended to provide 
a full-featured mail server. In effect I’m running Dovecot in a Docker 
container on Alpine Linux.

-F

Apple Mail and subfolders

2020-07-11 Thread Filip Hajný
Hi all,

does anybody here use MacOS (Catalina) Mail, who can confirm that subfolders 
(i.e. folders inside folders) work for them?

It seems that I cannot create/access Maildir subfolders at all. Subfolders 
created in Mail show up as '.folder\2esubfolder' on disk, suggesting that Apple 
Mail is URL-coding the dot separator before it passes it onto Dovecot. No such 
translation takes place when interpreting the IMAP tree though, resulting in 
subfolders rendered as plain entries with the dot separator preserved.

Subfolders can be created from elsewhere (SoGO, Roundube, Thunderbird) just 
fine and work here just fine, suggesting that all is well in terms of Dovecot 
configuration. Subfolders created here though show up as a proper hierarchy in 
Apple Mail, but their contents is not displayed, so the user thinks the 
subfolder is empty.

This definitely used to work fine in the past.

Running 2.3.10.1 as part of the Mailcow suite.

-F