stats module

Jeff Abrahamson jeff at p27.eu
Sun Nov 5 22:29:54 EET 2017


Doh.  Yes, that is why the file wasn't being read.  Thanks.

It turned out, moveover, that to get the inet listener to start, I
needed to do a restart, not just a reload (sudo service dovecot
reload).  I'm not sure why that should be.  But it's now working.


Meanwhile, I started seeing errors like this when I check mail:

    Nov  5 20:57:06 nantes-1 dovecot: imap(jeff): Error: stats:
open(/var/run/dovecot/stats-mail) failed: Permission denied

The comments on the wiki page tell me to make this socket mode 600 and
owned by the user that my mail process runs as.  I think this means
dovecot.  (I tried dovenull, that was wrong.)

    ╭╴ (master=)╶╮
    ╰ [T] jeff at nantes-1:p27 $ ll /var/run/dovecot/stats*
    srw------- 1 root    root 0 Nov  5 21:02 /var/run/dovecot/stats
    prw------- 1 dovecot root 0 Nov  5 21:02 /var/run/dovecot/stats-mail
    prw------- 1 root    root 0 Nov  5 21:02 /var/run/dovecot/stats-user
    ╭╴ (master=)╶╮
    ╰ [T] jeff at nantes-1:p27 $

But actually this might be tricky, since there are many such users,
depending on what we mean.

    root      7553  0.0  0.2  18244  3000 ?        Ss   Nov03   0:00
/usr/sbin/dovecot
    dovecot   7559  0.0  0.0   9520   960 ?        S    Nov03   0:00  \_
dovecot/anvil
    root     26686  0.0  0.2   9652  2376 ?        S    21:02   0:00  \_
dovecot/log
    root     26690  0.0  0.3  25300  4008 ?        S    21:02   0:00  \_
dovecot/config
    dovenull 26806  0.0  0.5  18820  5488 ?        S    21:02   0:00  \_
dovecot/imap-login
    root     26808  0.0  0.0   9516   948 ?        S    21:02   0:00  \_
dovecot/ssl-params
    jeff     26810  0.0  0.3  25852  3860 ?        S    21:02   0:00  \_
dovecot/imap

With a bit of trial-and-error, I see that the error goes away if I
change the owner to jeff.  It sounds like I need to create an imap-users
group and make the socket accessible to everyone in that group (mode
660).  But that's not really what the docs say.  Am I confused or is
this something I should suggest we change in the docs?

    https://wiki2.dovecot.org/Statistics

Jeff


On 04/11/17 21:06, Steffen wrote:
> Jeff Abrahamson wrote: > > On 03/11/17 17:43, Mark Moseley wrote: > >> > >> > >> On Fri, Nov
3, 2017 at 9:35 AM, Jeff Abrahamson <jeff at p27.eu > >>
<mailto:jeff at p27.eu>> wrote: > >> > >> Sorry, Aki, I don't follow you.
Did I do it wrong in the file > >> 91-stats that I shared in my original
mail (attached here)? > >> > > >>>> -rw-r--r-- 1 root root 1856 Nov 3
16:11 91-stats -rw-r--r-- > >>>> 1 root root 1430 Oct 31 16:33 > >>
99-mail-stack-delivery.conf > > >>>> The file 91-stats contains the
contents I pasted in my > >>>> earlier > >> mail. > >>>> I'm a bit
unclear what to check next. > > > Thanks. I tried simply removing the
socket listener, as I don't > > need it. Still no error, still no port
24242 listener. > > IMHO: the default dovecot.conf includes *.conf files
only. If you > haven't changed it, hence, try to rename the file into >
> 91-stats.conf > ^^^^^ >
-- 

Jeff Abrahamson
+33 6 24 40 01 57
+44 7920 594 255

http://p27.eu/jeff/



More information about the dovecot mailing list