Index | Thread | Search

From:
"Johannes Thyssen Tishman" <johannes@thyssentishman.com>
Subject:
[revision] mail/aerc: include pkg/README?
To:
<ports@openbsd.org>
Cc:
"Dylan D'silva" <dylan@dsilva.email>
Date:
Thu, 05 Sep 2024 12:52:38 +0200

Download raw body.

Thread
The email below was sent to the aerc-discuss mailing list a couple of
days ago. Is it worth adding a pkg/README for this?

2024-09-03T23:12:23Z "Dylan D'silva" <dylan@dsilva.email>:
Hello all,

After some digging I've come to a solution. For those on a BSD system
with large MAILDIR, you'll require something similar. Aerc uses
github.com/fsnotify/fsnotify to monitor changes to files. BSD system
rely on Kqueue which doesn't support recursive watching of files.
Therefore you require one file descriptor for each file.

Assuming you are running aerc from the current account. You can
change the limit to match your maildir size.

For me, I store my maildir in ~/Mail 
find . -type f | wc -l #counts number of files
71514

I run aerc from a staff account. Therefore I updated my /etc/login.conf
under staff to increase the openfile-cur size to 71600 and openfile-max
to 72000
 :openfiles-cur=71600:\
 :openfiles-max=72000:\

If you use a large login.conf you might want create a database version
with cap_mkdb /etc/login.conf see login.conf(5).


Then I changed kernel level file descriptor limit via

sysctl kern.maxfiles=72000

and adding that to /etc/sysctl.conf

This fixes the problem. You need to log out and back in for it to take
effect.

Something of note. This is also an issue with syncthing. One work around
that syncthing offers is to turn off file watching in advanced settings
and just doing periodic scans of the files. This lowers the file
descriptor requirements significantly. Obviously this is a development
effort though.

Regards
Dylan