Bug 239172 - mail/dovecot imap/pop3 stat-writer issue
Summary: mail/dovecot imap/pop3 stat-writer issue
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: amd64 Any
: --- Affects Only Me
Assignee: Larry Rosenman
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-07-12 17:54 UTC by Marek
Modified: 2019-07-19 02:52 UTC (History)
1 user (show)

See Also:
bugzilla: maintainer-feedback? (ler)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Marek 2019-07-12 17:54:25 UTC
Hi all :)

After mail/dovecot upgrade to v2.3.7 it seems something went wrong with stat-writer...

IMAP and POP3 logs:

Jul 12 19:45:34 mail dovecot: imap-login: Error: file_ostream.net_set_tcp_nodelay((conn:unix:/var/run/dovecot/stats-writer), TRUE) failed: Invalid argument
Jul 12 19:45:34 mail dovecot: imap-login: Error: file_ostream.net_set_tcp_nodelay((conn:unix:login), TRUE) failed: Invalid argument
Jul 12 19:45:35 mail dovecot: imap: Error: file_ostream.net_set_tcp_nodelay((conn:unix:/var/run/dovecot/stats-writer), TRUE) failed: Invalid argument
Jul 12 19:45:35 mail dovecot: imap: Error: file_ostream.net_set_tcp_nodelay((conn:unix:/var/run/dovecot/auth-master), TRUE) failed: Invalid argument
Jul 12 19:45:35 mail dovecot: imap-login: Login: user=<someone@domain.tld>, method=PLAIN, rip=192.168.0.28, lip=192.168.0.1, mpid=47811, TLS, session=<aelAen+NKpDAqAAc>
Jul 12 19:45:41 mail dovecot: imap(someone@domain.tld)<47811><aelAen+NKpDAqAAc>: Connection closed (UID SEARCH finished 6.727 secs ago) in=128 out=2015 deleted=0 expunged=0 trashed=0 hdr_count=0 hdr_bytes=0 body_count=0 body_bytes=0

Jul 12 19:51:21 mail dovecot: pop3-login: Error: file_ostream.net_set_tcp_nodelay((conn:unix:/var/run/dovecot/stats-writer), TRUE) failed: Invalid argument
Jul 12 19:51:21 mail dovecot: auth: Error: file_ostream.net_set_tcp_nodelay((conn:unix:/var/run/dovecot/stats-writer), TRUE) failed: Invalid argument
Jul 12 19:51:21 mail dovecot: pop3-login: Error: file_ostream.net_set_tcp_nodelay((conn:unix:login), TRUE) failed: Invalid argument
Jul 12 19:51:21 mail dovecot: pop3: Error: file_ostream.net_set_tcp_nodelay((conn:unix:/var/run/dovecot/stats-writer), TRUE) failed: Invalid argument
Jul 12 19:51:21 mail dovecot: pop3: Error: file_ostream.net_set_tcp_nodelay((conn:unix:/var/run/dovecot/auth-master), TRUE) failed: Invalid argument
Jul 12 19:51:21 mail dovecot: pop3-login: Login: user=<someone@domain.tld>, method=PLAIN, rip=192.168.0.33, lip=192.168.0.1, mpid=47877, TLS, session=<h+3jjn+NcPrAqAAh>
Jul 12 19:51:21 mail dovecot: pop3(someone@domain.tld)<47877><h+3jjn+NcPrAqAAh>: Disconnected: Logged out top=0/0, retr=0/0, del=0/0, size=0
Comment 1 Larry Rosenman freebsd_committer 2019-07-12 19:05:49 UTC
I'm seeing this too.  Looking at it. 
Thanks for the report.
Comment 2 commit-hook freebsd_committer 2019-07-12 19:22:28 UTC
A commit references this bug:

Author: ler
Date: Fri Jul 12 19:22:10 UTC 2019
New revision: 506487
URL: https://svnweb.freebsd.org/changeset/ports/506487

Log:
  mail/dovecot: stop spamming the log with EINVAL.

  PR:		239172
  Submitted by:	zillion1@o2.pl
  Obtained from:	dovecot mailing list.

Changes:
  head/mail/dovecot/Makefile
  head/mail/dovecot/files/patch-src_lib_ostream-file.c
Comment 3 Larry Rosenman freebsd_committer 2019-07-12 19:24:31 UTC
Fix committed.
Comment 4 Marek 2019-07-12 20:17:56 UTC
Confirmed, spamming logs has gone :)
Comment 5 VVD 2019-07-15 17:27:00 UTC
Still spam in log:
tail -f /var/log/dovecot/dovecot.log
Jul 15 19:51:24 imap-login: Error: file_ostream.net_set_tcp_nodelay(, TRUE) failed: Connection reset by peer
Jul 15 19:52:39 imap-login: Error: file_ostream.net_set_tcp_nodelay(, TRUE) failed: Connection reset by peer
Jul 15 19:58:43 imap-login: Error: file_ostream.net_set_tcp_nodelay(, TRUE) failed: Connection reset by peer
Jul 15 20:02:23 imap-login: Error: file_ostream.net_set_tcp_nodelay(, TRUE) failed: Connection reset by peer
Jul 15 20:03:57 imap-login: Error: file_ostream.net_set_tcp_nodelay(, TRUE) failed: Connection reset by peer
Jul 15 20:04:44 imap-login: Error: file_ostream.net_set_tcp_nodelay(, TRUE) failed: Connection reset by peer
Jul 15 20:04:44 imap-login: Error: file_ostream.net_set_tcp_nodelay(, TRUE) failed: Connection reset by peer
Jul 15 20:05:24 imap-login: Error: file_ostream.net_set_tcp_nodelay(, TRUE) failed: Connection reset by peer
Jul 15 20:06:39 imap-login: Error: file_ostream.net_set_tcp_nodelay(, TRUE) failed: Connection reset by peer
Jul 15 20:07:27 imap-login: Error: file_ostream.net_set_tcp_nodelay(, TRUE) failed: Connection reset by peer
Jul 15 20:08:28 imap-login: Error: file_ostream.net_set_tcp_nodelay(, TRUE) failed: Connection reset by peer
Jul 15 20:09:31 imap-login: Error: file_ostream.net_set_tcp_nodelay(, TRUE) failed: Connection reset by peer
Jul 15 20:12:23 imap-login: Error: file_ostream.net_set_tcp_nodelay(, TRUE) failed: Connection reset by peer
Jul 15 20:24:11 imap-login: Error: file_ostream.net_set_tcp_nodelay(, TRUE) failed: Connection reset by peer


Name           : dovecot
Version        : 2.3.7_1
Installed on   : Sat Jul 13 19:12:08 2019 MSK
Origin         : mail/dovecot
Architecture   : FreeBSD:10:amd64
Prefix         : /usr/local
Categories     : ipv6 mail
Licenses       : MIT, LGPL21
Maintainer     : ler@FreeBSD.org
WWW            : http://www.dovecot.org/
Comment        : Secure, fast and powerful IMAP and POP3 server
Options        :
        CDB            : off
        DOCS           : on
        EXAMPLES       : on
        GSSAPI_BASE    : off
        GSSAPI_HEIMDAL : off
        GSSAPI_MIT     : off
        GSSAPI_NONE    : on
        ICU            : on
        LDAP           : on
        LIBSODIUM      : off
        LIBWRAP        : off
        LUA            : off
        LUCENE         : off
        LZ4            : on
        MYSQL          : on
        PGSQL          : off
        SOLR           : off
        SQLITE         : off
        TEXTCAT        : off
        VPOPMAIL       : off
Comment 6 Larry Rosenman freebsd_committer 2019-07-15 17:37:11 UTC
that looks like a firewall issue....
Comment 7 VVD 2019-07-18 22:28:08 UTC
Probably it's incorrect disconnected clients.
Comment 8 Larry Rosenman freebsd_committer 2019-07-18 22:34:05 UTC
the latest port (2.3.7_3) doesn't log these any more.

from an upstream patch.
Comment 9 VVD 2019-07-19 02:52:41 UTC
(In reply to Larry Rosenman from comment #8)
Thanks, they has gone now.