I am using cyrus 3.12.0

I am the only user of the server, so overload is not an issue, but memory is. 
Recently I found that my server is meeting a lot of OOMs, and found this FAQ 
entry:

https://www.cyrusimap.org/imap/reference/faqs/o-toomanyprocesses.html

Okay, I don't need even remotely so many processes, so I added the following 
settings:

1. imapd.conf

cp_keepalive: 1
cp_keepalive_cnt: 3
cp_keepalive_idle: 15
cp_keepalive_intvl: 15

2. cyrus.conf

imaps         cmd="imapd -s -U 2 -T 30" listen="imaps" prefork=0 maxchild=5

I expected cyrus to be able to maintain 10 connections like this.

I have three clients: two desktop machines, and a smartphone with a k9-mail 
(thunderbird mobile).

Now none of my clients are able to connect. The attempt fails on trying to 
establish a TLS connecttion.
Restarting cyrus solves the issue temporarily, but I don't want to restart 
cyrus (do manual garbage collection) every hour.

Is this an issue, or am I missing some config parameter?

The output of ss --tcp | grep imaps

CLOSE-WAIT 518    0      [0000::serv:ipv6]:imaps       [000::k9ma:ipv6]:37018
CLOSE-WAIT 518    0      [0000::serv:ipv6]:imaps       [000::k9ma:ipv6]:40444
CLOSE-WAIT 518    0      [0000::serv:ipv6]:imaps       [000::k9ma:ipv6]:41550
CLOSE-WAIT 518    0      [0000::serv:ipv6]:imaps       [000::k9ma:ipv6]:42146
CLOSE-WAIT 518    0      [0000::serv:ipv6]:imaps       [000::k9ma:ipv6]:42524
CLOSE-WAIT 518    0      [0000::serv:ipv6]:imaps       [000::k9ma:ipv6]:43714
CLOSE-WAIT 518    0      [0000::serv:ipv6]:imaps       [000::k9ma:ipv6]:44948
CLOSE-WAIT 518    0      [0000::serv:ipv6]:imaps       [000::k9ma:ipv6]:45004
CLOSE-WAIT 518    0      [0000::serv:ipv6]:imaps       [000::k9ma:ipv6]:45012
CLOSE-WAIT 518    0      [0000::serv:ipv6]:imaps       [000::k9ma:ipv6]:47908
CLOSE-WAIT 518    0      [0000::serv:ipv6]:imaps       [000::k9ma:ipv6]:48890
CLOSE-WAIT 518    0      [0000::serv:ipv6]:imaps       
[0001:lap:top2:ipv6]:33372
CLOSE-WAIT 518    0      [0000::serv:ipv6]:imaps       
[0001:lap:top2:ipv6]:37448
CLOSE-WAIT 518    0      [0000::serv:ipv6]:imaps       
[0001:lap:top2:ipv6]:42248
CLOSE-WAIT 518    0      [0000::serv:ipv6]:imaps       
[0001:lap:top2:ipv6]:45768
CLOSE-WAIT 518    0      [0000::serv:ipv6]:imaps       
[0001:lap:top2:ipv6]:59704
ESTAB      0      0                               server.ipv4:imaps             
                         cnat.ipv4:4217
ESTAB      0      0      [0000::serv:ipv6]:imaps       [0000:lap:top:ipv6]:35222
ESTAB      0      0      [0000::serv:ipv6]:imaps       [000::k9ma:ipv6]:39070
ESTAB      0      0      [0000::serv:ipv6]:imaps       [000::k9ma:ipv6]:41246
ESTAB      0      0      [0000::serv:ipv6]:imaps       [000::k9ma:ipv6]:47480
ESTAB      0      0      [0000::serv:ipv6]:imaps       [000::k9ma:ipv6]:47922
ESTAB      517    0      [0000::serv:ipv6]:imaps       [000::k9ma:ipv6]:43734
ESTAB      517    0      [0000::serv:ipv6]:imaps       
[0001:lap:top2:ipv6]:50438

That's 22 connections.
1. Why are there so many?
I expected to have one connection per device.

2. Does the -U option count different connections from the same device (IDLE) 
as different connections?

3. Why are the connections refused? I expected cyrus, if it is lacking 
resources (the -U option), to evict older clients to give way to the new ones. 
Is it doing something else?

4. Why are there so many connections "CLOSE-WAIT"?

------------------------------------------
Cyrus: Info
Permalink: 
https://cyrus.topicbox.com/groups/info/T22ff1c7d14d4cd97-Mb30cc59c1fbdc685ea733e7e
Delivery options: https://cyrus.topicbox.com/groups/info/subscription

Reply via email to