[exim] quota warning problems when maildir_use_size_file is …

Top Page
Delete this message
Reply to this message
Author: Odhiambo G. Washington
Date:  
To: exim-users
Subject: [exim] quota warning problems when maildir_use_size_file is activated

I am wondering if my way of asking questions sucks ;)
Or could this be an FAQ that I am missing?
Or do I just attach the files mentioned? I've done that, if it might
help save time for other users to respond with ideas.


No responses/ideas so far.

----- Forwarded message from "Odhiambo G. Washington" <wash@???> -----

From: "Odhiambo G. Washington" <wash@???>
To: exim-users@???
Date: Wed, 29 Jun 2005 12:56:58 +0300
Subject: [exim] maildir_use_size_file and phony quota warnings.
X-Mailer: Mutt 1.5.9i (2005-03-13)

Hello,

I am running Exim 4.51, but the problem I am having comes from way
back. It's always been there and now I wonder if anyone knows a
solution.

What happens is that when I enable maildir_use_size_file in my
local_delivery transport, the maildirsize file is created in
{home}/Maildir. The presence of this file makes my users to get
an bar that shows them the percentage of the 100MB quota that
their maildir has taken. This is when they view their e-mails
via a web interface - squirrelmail+courier-imap.

The quota_warning function seems to work fine, but only until
I add the maildir_use_size_file option to the transport. Then
all hell breaks: I begin to receive complaints from clients
who receive quota warnings they believe are wrong/inappropriate,
because on the web interface, they can clearly see that they
are not about to exceed quota.

I have put the following files for public scrutiny:

du.txt        - Output of `du -hc` from ~userx/Maildir/
maildirsize    - contents of maildirsize from ~userx/Maildir/
transport.txt    - My local_delivery transport


They are all here: http://ns2.wananchi.com/~wash/maildirsize/

In this particular case, userx received a quota warning when
his maildir had just 4MB.

Another thing I'd like to see with the quota_warning being sent
out: What variable does Exim store the calculated maildir size
in? can I use the value from that variable in my quota warning
message, as in, "your current mailbox size is 75MB" or such?


I'll be grateful if anyone can help me with the correct advise
towards solving this strange problem. It could be caused by me
but I am sincerely not sure how.


        cheers
       - wash 
+----------------------------------+-----------------------------------------+
Odhiambo Washington                    . WANANCHI ONLINE LTD (Nairobi, KE)  |
wash () WANANCHI ! com            . 1ere Etage, Loita Hse, Loita St.,  |
GSM: (+254) 722 743 223            . # 10286, 00100 NAIROBI             |
GSM: (+254) 733 744 121            . (+254) 020 313 985 - 9             |
+---------------------------------+------------------------------------------+
"Oh My God! They killed init! You Bastards!"  
                         --from a /. post

# This transport is used for local delivery to user mailboxes in Maildir
# format. By default it will be run under the uid and gid of the local user.

local_delivery:
 driver              = appendfile
 check_string        =
 directory           = ${home}/Maildir/
 create_directory
 directory_mode      = 0700
 delivery_date_add
 envelope_to_add
 group               = mail
 maildir_format
 maildir_tag         = ,S=$message_size
 maildir_use_size_file
 message_prefix      = ""
 message_suffix      = ""
 no_mode_fail_narrower
 quota               = ${lookup {$local_part} lsearch \
                    {/usr/local/etc/exim/quota-maps}{$value}{100}}M
 no_quota_is_inclusive
 quota_size_regex    = ,S=(\d+)$
 quota_warn_message  = "\
                      To: $local_part@$domain\n\
                      Subject: Your mailbox at $domain server almost filled up.\n\n\
                      This message is automatically created by mail delivery software \n\
                      (SMTP/POP3) at $domain.\n\
                      The size of your mailbox has exceeded a warning threshold\n\
                      set by the System Administrator.\n\
                      Please remove mails from your mailbox in order to avoid possible\n\
                      rejection of incoming mail.\n\n\
                      Feel free to contact our tech support if you encounter any problems.\n\n\
                      When you receive this message, it means that your current\n\
                      mailbox size is approaching the QUOTA allowed by Wananchi Online Ltd.\n\
                      You need to clean up/delete old msgs.\n\
                      If your e-mail software has a setting that leaves a copy of the\n\
                      message on the server, please also set the option that deletes the\n\
                      message from the server when you delete your local copy."
 quota_warn_threshold = 75%
 return_path_add
 mode                 = 0660
 shadow_transport     = backup_service_delivery
 shadow_condition     = ${lookup{$local_part@$domain}lsearch{/usr/local/etc/exim/mail_backup_users}{1}{0}}

104857600S,0C
2704189 114
4669 1
2838 1
212999 1
160404 1
446673 1
129896 1
1420 1
213742 1
1117782 1
3303 1
397362 1
7668 1
1961 1
2428 1
2985924 1
4302 1
2412 1
20715 1
1963 1
4326 1
3520 1
9715 1
199243 1
25697 1
10249 1
400314 1
2615 1
314111 1
2554 1
11333 1
356495 1
213141 1
312370 1
2878 1
428681 1
2558932 1
310014 1
4128 1
41514 1
1546 1
5043 1
79409 1
51804 1
2135 1
2422052 1
4415192 1
142767 1
2258 1
4210 1
1435 1
2961 1
2137 1
130435 1
210391 1
2294 1
4079 1
9082 1
3580 1
653987 1
335983 1
840399 1
312907 1
347148 1
7810 1
6682 1
128422 1
45691 1
3633 1
3471 1
2259 1
672511 1
1173 1
2568 1
2568 1
2663 1
121643 1
338255 1
275639 1
2905 1
6337 1
4075 1
429498 1
39123 1
2839941 1
4053 1
2720 1
2215 1
6335 1
4497 1
2062 1
2363 1
2787 1
3107 1
4716 1
49225 1
2407 1
47490 1
2529 1
5149 1
251623 1
1488675 1
6072 1
106316 1
2986919 1
369601 1
1217 1
2903 1
3654 1
8463 1
5317 1
9284 1
15295 1
4416 1
1103 1
2290 1
2011 1
8211 1
555630 1
2613 1
105511 1
4932 1
3219 1
24269 1
7264647 1
    -7264647           -1
644072 1
        6268            1
        6799            1
8808 1
1291172 1
8827 1
293464 1
5815 1
5668 1
341827 1
126208 1
3077 1
2604 1
644881 1
709507 1
137528 1
198635 1
4473 1
217327 1
36940 1
173245 1
281457 1
2351 1
3716 1
6290 1
8755 1
149123 1
2775 1
9783 1
7226 1
1800540 1
295350 1
2620 1
1518 1
2836 1
1855 1
111943 1
345270 1
6501 1
5935 1
6932 1
2225 1
250207 1
2151 1
20836 1
5795 1
3266464 1
1123 1
2728 1
55910 1
164758 1
11018 1
7069 1
193968 1
5440 1
11854 1
2577 1
6578 1
2917 1
1224 1
5346 1
102589 1
581649 1
24992 1
8895 1
6022 1
33085 1
6664 1
7102 1
277826 1
3248616 1
10062 1
2630 1
4320 1
2168 1
2783 1
110093 1
3256 1
19363 1
153668 1
194063 1
18632 1
2933 1
24323 1
713107 1
1708454 1
10088 1
3284 1
42429 1
3512 1
81196 1
130891 1
22369 1
296233 1
64659 1
6364 1
708320 1
4228 1
3638 1
36990 1
1514 1
302226 1
4985 1
419485 1
4735 1
507057 1
231911 1
143830 1
24575 1
11657 1
3923446 1
7451 1
2860 1
7674 1
2233 1
16805 1
582478 1
567301 1
396586 1
6040245 1
1661 1
8112 1
35632 1
252801 1
11900 1
3744 1
41048 1
564450 1
8861 1
3304 1
2165 1
2150 1
114908 1
2711 1
64378 1
4440 1
2886 1
1162673 1
7394 1
8343 1
5288 1
37584 1
6410 1
11417 1
12967 1
8602 1
2665421 1
11590 1
1250 1
113662 1
21882 1
6004 1
7444 1
7112 1
108779 1
1736767 1
8276 1
66911 1
12282 1
296941 1
4276414 1
1227 1
3471 1
5873 1
637779 1
941134 1
121110 1
9239 1
9368 1
     -941134           -1
1701 1
2243 1
5732 1
4030 1
176500 1
44650 1
2228 1
3414519 1
733980 1
147411 1
3409 1
521905 1
11994 1
105732 1
105226 1
8269 1

[root@ns2]#du -hc
2.0K    ./tmp
1.1M    ./new
2.0K    ./cur
2.0K    ./.Drafts/tmp
 14K    ./.Drafts/cur
2.0K    ./.Drafts/courierimapkeywords
2.0K    ./.Drafts/new
 26K    ./.Drafts
2.0K    ./.mario/tmp
 12K    ./.mario/cur
2.0K    ./.mario/courierimapkeywords
2.0K    ./.mario/new
 24K    ./.mario
2.0K    ./.Trash/tmp
2.0K    ./.Trash/new
2.0K    ./.Trash/cur
2.0K    ./.Trash/courierimapkeywords
 14K    ./.Trash
2.0K    ./courierimapkeywords
2.0K    ./.Sent/tmp
2.7M    ./.Sent/cur
2.0K    ./.Sent/courierimapkeywords
2.0K    ./.Sent/new
2.7M    ./.Sent
4.0M    .
4.0M    total