[Dovecot] per user quota using LDAP entries

2007-05-22 Thread Kenneth Oncinian

Hi List,

This is my first post to this list so please be gentle :-).
First of all, kudos to the developers of dovecot!

Im trying to implement quota, and I followed the instructions in the wiki.
My problem is the quota specified per user is not being honored, only the
global quota setting.
I do have an quota = maildir:storage=204800 in the plugin area and enabled
quota in the mail_plugins for both imap and pop3.

This is my user attribute in /etc/dovecot-ldap.conf:
user_attrs = homeDirectory=home,uidNumber=uid,gidNumber=gid,mailQuota=quota
wherein the mailQuota attribute has an entry of mailQuota:
maildir:storage=30720.

So i was expecting of a 300MB quota for that user, but dovecot is using the
global quota of 200MB instead of 300MB.

My dovecot version is 1.0.0

My dovecot.conf:
---
# /etc/dovecot.conf
log_path: /var/log/dovecot.log
protocols: imap pop3
login_dir: /var/run/dovecot/login
login_executable(default): /usr/libexec/dovecot/imap-login
login_executable(imap): /usr/libexec/dovecot/imap-login
login_executable(pop3): /usr/libexec/dovecot/pop3-login
login_greeting_capability(default): yes
login_greeting_capability(imap): yes
login_greeting_capability(pop3): no
mail_location: /var/mail/vhost/%u
mail_debug: yes
maildir_copy_with_hardlinks: yes
maildir_copy_preserve_filename: yes
mail_executable(default): /usr/libexec/dovecot/imap
mail_executable(imap): /usr/libexec/dovecot/imap
mail_executable(pop3): /usr/libexec/dovecot/pop3
mail_plugins(default): quota imap_quota trash
mail_plugins(imap): quota imap_quota trash
mail_plugins(pop3): quota
mail_plugin_dir(default): /usr/lib/dovecot/imap
mail_plugin_dir(imap): /usr/lib/dovecot/imap
mail_plugin_dir(pop3): /usr/lib/dovecot/pop3
pop3_client_workarounds(default):
pop3_client_workarounds(imap):
pop3_client_workarounds(pop3): outlook-no-nuls oe-ns-eoh
auth default:
 verbose: yes
 debug: yes
 debug_passwords: yes
 passdb:
   driver: ldap
   args: /etc/dovecot-ldap.conf
 userdb:
   driver: passwd
 userdb:
   driver: ldap
   args: /etc/dovecot- ldap.conf
 userdb:
   driver: prefetch
plugin:
 quota: maildir:storage=204800
 trash: /etc/dovecot-trash.conf
---

my dovecot-ldap.conf
--
hosts = localhost.localdomain
dn = cn=Directory Manager
dnpass = xx
tls = no
auth_bind = no
ldap_version = 3
base = ou=people, dc=xx, dc=xx, dc=xx
user_attrs = homeDirectory=home,uidNumber=uid,gidNumber=gid,mailQuota=quota
pass_attrs = uid=user,userPassword=password
pass_filter = ((objectClass=posixAccount)(uid=%u))
default_pass_scheme = LDAP-MD5
--

sample LDAP query:
--
ldapsearch -x -Z '(uid=kenneth.oncinian)'
# LDAPv3
# base  with scope sub
# filter: (uid=kenneth.oncinian)
# requesting: ALL
#

# kenneth.oncinian, People, ph.panasonic.com
dn: uid=kenneth.oncinian,ou=People, dc=xx,dc=xx,dc=xx
givenName: Kenneth
sn: Oncinian
telephoneNumber: xxx-
loginShell: /bin/bash
gidNumber: 2516
uidNumber: 1000
mail: [EMAIL PROTECTED]
facsimileTelephoneNumber: xxx 
objectClass: top
objectClass: person
objectClass: organizationalPerson
objectClass: inetorgperson
objectClass: posixAccount
objectClass: account
objectClass: mailgroup
objectClass: mailgroupmanagement
objectClass: mailgroupmanagement-globalconfig
objectClass: mailgroupmember
objectClass: mailrecipient
objectClass: netscapemailserver
objectClass: nsmailclient
objectClass: ntuser
objectClass: sambaSamAccount
objectClass: proxyaccess
objectClass: jabberaccess
uid: kenneth.oncinian
preferredLanguage: en
cn: Kenneth Oncinian
homeDirectory: /var/mail/vhost/kenneth.oncinian
ou: Information Systems Department (ISD)
x500UniqueIdentifier:
mailAlternateAddress: [EMAIL PROTECTED]
ntUserDomainId: kenneth.oncinian
ntUserCreateNewAccount: true
ntUserDeleteAccount: true
sambaSID: S-1-5-21-1685363153-499155089-1962420841-3000
sambaPrimaryGroupSID: S-1-5-21-1685363153-499155089-1962420841-3001
displayName: Kenneth Oncinian
sambaPwdMustChange: 2147483647
sambaPasswordHistory:


sambaAcctFlags: [U  ]
myproxyaccess: yes
myjabberaccess: yes
sambaPwdCanChange: 1179303932
sambaLMPassword: xx
sambaNTPassword: xx
sambaPwdLastSet: 1179303932
mailQuota: maildir:storage=30720

# search result
search: 3
result: 0 Success

# numResponses: 2
# numEntries: 1
-- snip--



thanks and best regards,
Kenneth


Re: [Dovecot] No authentication sockets found

2007-05-22 Thread funkypunky drunky

Hi Timo,
You said it was solved since 1.0.rc29 but i am using 1.0.0 . After i try to
start dovecot while dovecot is working i take below error

May 22 12:36:03 mailtest mail:err|error dovecot: imap-login: No
authentication sockets found
Maybe you can check this issue.
Thanx and best regards Timo.


2007/5/21, Timo Sirainen [EMAIL PROTECTED]:


On Mon, 2007-05-21 at 12:10 +0300, funkypunky drunky wrote:
 Hi stewart i can see these errors in my log if i try to start dovecot
while
 dovecot is working.
..
 May 21 11:59:39 mailtest mail:err|error dovecot: imap-login: No
 authentication sockets found

This should have been fixed already:

v1.0.rc29 2007-03-28  Timo Sirainen [EMAIL PROTECTED]

   - If Dovecot is tried to be started when it's already running,
don't
 delete existing auth sockets and break the running Dovecot





Re: [Dovecot] Updated v1.1 and summer plans

2007-05-22 Thread M1

Dear Timo,

How about managedsieve?

Regards,
Steve

Timo Sirainen [EMAIL PROTECTED] wrote in message 
news:[EMAIL PROTECTED]






Re: [Dovecot] [PATCH] add some const's

2007-05-22 Thread Timo Sirainen
On Tue, 2007-05-22 at 15:44 +0400, Andrey Panin wrote:
 Add some const's. I think patch is self-explaining :)

Committed. I even managed to do the import right the first time. :)



signature.asc
Description: This is a digitally signed message part


[Dovecot] shared folders

2007-05-22 Thread David Obando
Dear all,

I would like to use shared folders but I'm not quite sure whether
Dovecot supports it the way I want it:

-user A should be able to share a folder with users B, C, D
-B, C and D should have read-access to this folder

Did anyone implement shared folders like this?

Regards,
David


-- 
The day microsoft makes something that doesn't suck is the day they start 
making vacuum cleaners.
gpg --keyserver pgp.mit.edu --recv-keys 1920BD87
Key fingerprint = 3326 32CE 888B DFF1 DED3  B8D2 105F 29CB 1920 BD87



Re: [Dovecot] [Blasphemy] Can I build dovecot with -fstack-protector?

2007-05-22 Thread Ralf Hildebrandt
* Uldis Pakuls [EMAIL PROTECTED]:

 In Debian bug reports I found following post (15/04/2007):
 -fstack-protector works fine with glibc 2.5, or with '-lssp' if ssp 
 support is /not/ included in libc. Debian 4.0 is currently broken in 
 this way (as of libc6 2.3.6.ds1-13), so it would be nice to have a 
 configure test to work around an affected libc.

Argh. It works now.

-- 
Ralf Hildebrandt ([EMAIL PROTECTED]) [EMAIL PROTECTED]
Postfix - Einrichtung, Betrieb und Wartung   Tel. +49 (0)30-450 570-155
http://www.arschkrebs.de
If your mission to another star *depends* on every single piece of
complex equipment staying up with zero reboots for 200+ years, you
have some serious technology problems.   -- Linus Torvalds


[Dovecot] Quota warning message ala courier

2007-05-22 Thread Ralf Hildebrandt
I have to face it, my users are retards:

* either they're using crap MUAs which will not display their quota to them
* or they're using POP with leave mail on server and will never
  notice their quota, unless it's too late
* and once their quota is exceeded, their mails will bounce -- they'll
  never notice that, though. 

Thus I need a feature in dovecot that will tell them via email:

Level1: You ALMOST exceeded your quota, you're at 90% now
Level2: You're very close to exceededin your quota, you're at 95% now
Level3: Would you please clean up now? You're at 99% now

-- 
Ralf Hildebrandt ([EMAIL PROTECTED]) [EMAIL PROTECTED]
Postfix - Einrichtung, Betrieb und Wartung   Tel. +49 (0)30-450 570-155
http://www.arschkrebs.de
Hardware: the parts of a computer that can be kicked.   -- Jeff Pesis  


Re: [Dovecot] Quota warning message ala courier

2007-05-22 Thread Xavier Beaudouin

Hi there,

On Mon, 21 May 2007, Ralf Hildebrandt wrote:


I have to face it, my users are retards:


Every one have such users... :)


* either they're using crap MUAs which will not display their quota to them
* or they're using POP with leave mail on server and will never
 notice their quota, unless it's too late
* and once their quota is exceeded, their mails will bounce -- they'll
 never notice that, though.

Thus I need a feature in dovecot that will tell them via email:

Level1: You ALMOST exceeded your quota, you're at 90% now
Level2: You're very close to exceededin your quota, you're at 95% now
Level3: Would you please clean up now? You're at 99% now


Personaly I do that using lmtp (http://pll.sf.net/) that does this kind of 
warning.


Since lmtpd is also a lmtp client, it can reply with a temp fail (eg 450) 
to postfix for several days Avoiding bounces...


/Xavier


[Dovecot] simultaneous access to folder

2007-05-22 Thread David Lee
We have for many years been a UW-IMAP site, with users having their own
traditional, private, mbox-format INBOX and folders: almost (but not
quite) no complications of shared or simultaneous access.  We have just
completed a transparent transition to dovecot (official 1.0.0 release).

But we have one residual issue affecting one important user account.

UW-IMAP specifically only allows single access to mbox folders.  If
different IMAP connections are attempted to such a folder, the latest
attempt kills off earlier connections.  (That's just the way it works,
which was mostly fine for us.)

On this particular account we had explicitly set two folders to UW-IMAP's
different mbx format, so that a group of staff could simultaneously
access that folder and delete messages.  This is by a single, common,
id/pw account.

But dovecot doesn't support mbx format.

Is there a way for us to set up such a group-access folder under dovecot?
I've checked wiki pages such as http://wiki.dovecot.org/SharedMailboxes;
but that doesn't seem to be clear on the particular matter of which
formats are suitable for such simultaneous access.  It talks about
different users accessing a folder; in our case it is multiple instances
of the the same user.  Under dovecot, can we simply let it be mbox
format?  And can dovecot (unlike UW-IMAP) then handle the simultaneous
access?

[Background: this is just two folders (amongst many) on one username; the
overall service successfully handles over 15,000 usernames.  And the
solution (work-around) will only need to last a few months until that
whole account is Exchange-ified (but let's not digress...!)]

If I've missed something on the wiki which addresses this matter, point me
in the right direction...


-- 

:  David LeeI.T. Service  :
:  Senior Systems ProgrammerComputer Centre   :
:  UNIX Team Leader Durham University :
:   South Road:
:  http://www.dur.ac.uk/t.d.lee/Durham DH1 3LE:
:  Phone: +44 191 334 2752  U.K.  :


Re: [Dovecot] Quota warning message ala courier

2007-05-22 Thread Gabriel Millerd

On 5/21/07, Ralf Hildebrandt [EMAIL PROTECTED] wrote:

I have to face it, my users are retards:

Level1: You ALMOST exceeded your quota, you're at 90% now
Level2: You're very close to exceededin your quota, you're at 95% now
Level3: Would you please clean up now? You're at 99% now



I use dovecot imap, pop, lda + exim with maildir++ quotas all sql
backended. I have a small perlscript that uses
mail::imapclient-append() to place a message in their inbox detailing
something similar to your 'level' information as well as a dspam like
alert if need be and a few other things. I use a custom msgid so that
i can easily 'replace' the message with a new one. So in your level
example as they rise from 1,2,3 they would only see 3 if they never
saw 1 or 2 as new message. Back dating the message also helps to keep
it noticed.

If you use dovecot's lda your quite able to do something at that
moment to check the quota and toss a crafted message into the mix
using the deliver script.

I think an entry on the dovecot wiki dealing with one of the quotas
plugins mentions this.

If your using a filesystem quota and have real users a script wouldn't
be hard to craft to do the warn/hard messages either. But pushing a
lot of warnings into the inbox would be my fear which is why i replace
mine.



--
Gabriel Millerd


Re: [Dovecot] simultaneous access to folder

2007-05-22 Thread Chris Wakelin
David Lee wrote:
 We have for many years been a UW-IMAP site, with users having their own
 traditional, private, mbox-format INBOX and folders: almost (but not
 quite) no complications of shared or simultaneous access.  We have just
 completed a transparent transition to dovecot (official 1.0.0 release).

Congratulations! We did this nearly two years ago and now I'm using
Dovecot proxying to move users transparently to Exchange (against my
better judgement/prejudices) :(

 But we have one residual issue affecting one important user account.
 
 UW-IMAP specifically only allows single access to mbox folders.  If
 different IMAP connections are attempted to such a folder, the latest
 attempt kills off earlier connections.  (That's just the way it works,
 which was mostly fine for us.)
 
 On this particular account we had explicitly set two folders to UW-IMAP's
 different mbx format, so that a group of staff could simultaneously
 access that folder and delete messages.  This is by a single, common,
 id/pw account.
 
 But dovecot doesn't support mbx format.
 
 Is there a way for us to set up such a group-access folder under dovecot?
 

snip

Dovecot is fine with multiple clients accessing (as the same user) an
mbox. We converted all our similar mbx-format files back to mbox when we
migrated.

Chris

-- 
--+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+---+-
Christopher Wakelin,   [EMAIL PROTECTED]
IT Services Centre, The University of Reading,  Tel: +44 (0)118 378 8439
Whiteknights, Reading, RG6 2AF, UK  Fax: +44 (0)118 975 3094


[Dovecot] Quota handling - opportunity for new Feature?

2007-05-22 Thread Charles Marcus
This initial proposal for a Feature Request is the result of my desire 
to implement quotas, but not have the attendant headaches that 
inevitably accompany its implementation.


Ralf Hildebrandt wrote:
 I have to face it, my users are retards:

Is there any other kind of user?  ;)

snip

 Thus I need a feature in dovecot that will tell them via email:

 Level1: You ALMOST exceeded your quota, you're at 90% now
 Level2: You're very close to exceededin your quota, you're at 95%
 now
 Level3: Would you please clean up now? You're at 99% now

What I'd *really* like to see implemented is something along the lines 
outlined below - but of course, this will depend entirely on whether or 
not Timo thinks it is doable - or desirable...


I know this would only be applicable if also using the dovecot LDA, 
because what I want to do requires cooperation at both the deliver and 
pop/imap ends...


1. Have two 'special' user-specific folders (by special, I mean like the 
Drafts, Sent, Templates folders) that dovecot controls:
  a) one, that the user has read-only access to and shows up in his 
folders list, that is used only for system-related messages, like 
over-quota notices - and maybe even user-specific log-type errors could 
be delivered here?
  b) and one (hidden) that the user does *not* have access to, to 
temporarily hold messages that come in that are unable to be delivered 
due to an over-quota condition


2. When user is over quota, have LDA deliver to folder b (yes, accept 
the message for delivery from the sending mta), and then generate an 
over-quota message that is delivered to folder a.


Optionally, a bounce could be generated to the sender, informing them 
that their message is being 'held in queue' or something to that effect, 
due to the recipient being over-quota.


3. Once the user deletes enough mail to come back under quota, dovecot 
would then move messages from the 'over-quota' folder to his Inbox.


Ok, am willing to hear reasons how/why this is a terrible idea... :)

--

Best regards,

Charles Marcus
I.T. Director
Media Brokers International
678.514.6200 x224
678.514.6299 fax


Re: [Dovecot] newbie with dovecot acls needs a little help :-)

2007-05-22 Thread Rachid Zarouali
On Fri, May 11, 2007 at 04:22:46PM +0300, Timo Sirainen wrote:
 On Wed, 2007-04-25 at 18:49 +0200, Rachid Zarouali wrote:
  hy all,
  
  i'm trying to make an acl so a local unix user 'sie' can access exalead 
  mboxes.
  my exalead mboxes are stored in :
  /opt/exalead/mail/sie/
 ..
  mail_extra_groups: exalead
  mail_location: mbox:/opt/exalead/mail
 
 A bit late, but if you haven't figured out anything yet:
 
 ACL plugin can only be used to remove permissions that would otherwise
 be given by filesystem permissions. So I guess your problem is that
 whatever user is trying to access the sie mboxes doesn't have permission
 to do so. Is it really enough to have users in exalead group to be able
 to access the mboxes? Anything in Dovecot's logs?
well here is how i tricked it:

i checked the umask for the exalead account is : 0002
i made sie member of the exalead group
in his $HOME dir , i made a symlink to /opt/exalead/mail/sie/ for the mail dir.
this way, the sie user will have it's own dovecot index and log files and 
can access the imap mailboxes readonly mode.

checking dovecot logs everything works well 
and using mutt i can access the mailboxes in readonly mode.
 



-- 
Rachid Zarouali
Administrateur Systèmes/Applications
AFNIC
[EMAIL PROTECTED]
01.39.30.83.47


Re: [Dovecot] Replication plans

2007-05-22 Thread Troy Benjegerdes
  This increases communication and locking significantly. The locking alone 
  will likely be a choke point. 
 
 My plan would require the locking only when the mailbox is being updated
 and the global lock isn't already owned by the server. If you want to
 avoid different servers from constantly stealing the lock from each
 others, use different ways to make sure that the mailbox normally isn't
 modified from more than one server.
 
 I don't think this will be a big problem even if multiple servers are
 modifying the same mailbox, but it depends entirely on the extra latency
 caused by the global locking. I don't know what the latency will be
 until it can be tested, but I don't think it should be much more than
 what a simple ping would give over the same network.

Best case, when all the nodes, and the network is up, locking latency
shouldn't be much longer than say twice the RTT. But what really
matters, and causes all the nasty bugs that even single-master
replication systems have to deal with is the *worst case* latency. So
everything is going along fine, and then due to a surge in incoming
spam, one of your switches starts dropping 2% of the packets, and the
server holding a lock starts taking 50ms instead of 1ms to respond to an
incoming packet. 

Now your previous lock latency of 1ms could easily extend into seconds if
a couple of responses to lock requests don't get through. And your 16
node imap cluster is now 8 times slower than a single server, instead of
8 times faster ;)

The nasty part about this for imap is that we can't ever have a UID be
handed out without *confirming* that it's been replicated to another
server before sending out the packet. Otherwise you can get in the
situation where node A sends out a new UID to a client out it's public
NIC card, while in the meantime, it's internal NIC melted so the update
never got propagated, so node B,C, and D  decides ooops, node A is
dead, we are stealing his lock, and B takes over the lock and allocates
the same UID to a different message, and now the CEO didn't get that
notice from the SEC to save all his emails.


Once you decide you want replication, you pretty much have to go all the
way to synchronous replication, and now you have a learning curve and
complexity issue that's going to be there whether it's dovecot
replication, or a cluster filesystem that's doing the dirty work for
you.


-- 
--
Troy Benjegerdes'da hozer'[EMAIL PROTECTED]  

Somone asked me why I work on this free (http://www.fsf.org/philosophy/)
software stuff and not get a real job. Charles Shultz had the best answer:

Why do musicians compose symphonies and poets write poems? They do it
because life wouldn't have any meaning for them if they didn't. That's why
I draw cartoons. It's my life. -- Charles Shultz


Re: [Dovecot] need some help please

2007-05-22 Thread Scott Silva
Timo Sirainen spake the following on 5/22/2007 5:38 AM:
 On Mon, 2007-05-21 at 16:09 -0700, Scott Silva wrote:
 # Protocols we want to be serving: imap imaps pop3 pop3s
 # If you only want to use dovecot-auth, you can set this to none.
 #protocols = imap imaps pop3 pop3s
 /quote

 So this is NOT the default, although the conf file states such?
 
 Where did you get the config file? The default config file that comes in
 tarball is the same as in http://dovecot.org/doc/dovecot-example.conf
 and there's no pop3 in the protocols line. If some distribution changed
 that, it should be fixed.
 
This was from an RPM created in one of the CentOS add-on packagers.
I ran a dovecot -n against this being commented and un- commented and didn't
see any difference. The packager must have found a way to change the defaults.

Can that be done at compile time or could the code have been modified?

-- 

MailScanner is like deodorant...
You hope everybody uses it, and
you notice quickly if they don't



Re: [Dovecot] May 21 09:13:14 mail dovecot: imap-login: No authentication sockets found

2007-05-22 Thread Troy Engel

[EMAIL PROTECTED] wrote:
Yes I knew I was authenticating against pam.  Didnt do an ls -l of the 
/var/run/dovecot.  Wouldnt a restart of dovecot fix that though?


Correct, the concept was *before* you restarted the daemon, to try and 
capture as much info first. It's hard when you're under the gun and need 
to restore services, but if it happens again I'd suggest scraping the 
system for clues for a few minutes. (ls -laR important dirs like 
/var/run/dovecot, ps -ef, maybe some lsof and lslk action, etc.)


-te

--
Troy Engel | Systems Engineer
Fluid, Inc | http://www.fluid.com


Re: [Dovecot] Quota handling - opportunity for new Feature?

2007-05-22 Thread Gabriel Millerd

On 5/22/07, Charles Marcus [EMAIL PROTECTED] wrote:

1. Have two 'special' user-specific folders (by special, I mean like the
Drafts, Sent, Templates folders) that dovecot controls:


  These are just special in terms of the client side of things. The
only special folder might be 'Trash' and various '.expunge' folders if
you go that route. This can be seen by the large number of people with
Sent, Sent-Mail, Drafts, Postponsed, Junk Mail (and all the variants
Outlook has created on the phrase 'junk mail' over the years)


   a) one, that the user has read-only access to and shows up in his
folders list, that is used only for system-related messages, like
over-quota notices - and maybe even user-specific log-type errors could
be delivered here?
   b) and one (hidden) that the user does *not* have access to, to
temporarily hold messages that come in that are unable to be delivered
due to an over-quota condition


   Your taking control of my email and not delivering it? In my
experience this would cause both a potential backlash and a people
resending mail. Especially since people really only look at their
INBOX for new mail or particular folders they have scripted. Using a
'poll all fodlers for new mail' I could see I had new mail in your 'a'
folder. But that would be the only way.


2. When user is over quota, have LDA deliver to folder b (yes, accept
the message for delivery from the sending mta), and then generate an
over-quota message that is delivered to folder a.

Optionally, a bounce could be generated to the sender, informing them
that their message is being 'held in queue' or something to that effect,
due to the recipient being over-quota.

3. Once the user deletes enough mail to come back under quota, dovecot
would then move messages from the 'over-quota' folder to his Inbox.

Ok, am willing to hear reasons how/why this is a terrible idea... :)



  This is how it actually works right now if configured, only the 'B'
folder is sender's /var/mail/spool and the 'a' folder is a intelligent
client like thunderbird or squirrelmail with a indicator that goes
nuts at a certain % full.

  Off topic but you could also wrap your MTA (easily do this with
exim and I am sure others) to 'deny message  = Achtung! your so over
quota man\ncondition = ${run{gimmequota.pl}}\nhosts = local_domains
if you want that instant 'halt your over quota' experience.

--
Gabriel Millerd


Re: [Dovecot] Quota handling - opportunity for new Feature?

2007-05-22 Thread Charles Marcus

Gabriel Millerd wrote:

On 5/22/07, Charles Marcus [EMAIL PROTECTED] wrote:

1. Have two 'special' user-specific folders (by special, I mean
like the Drafts, Sent, Templates folders) that dovecot controls:



These are just special in terms of the client side of things.


Special, in that the user/client doesn't have full control of them, 
dovecot does.



This can be seen by the large number of people with Sent, Sent-Mail,
Drafts, Postponsed, Junk Mail (and all the variants Outlook has
created on the phrase 'junk mail' over the years)


I know - I'd love a way to define in dovecot to clean these kinds of 
things up too... maybe a list of folders to 'consolidate' into the 
specifid/preferred folder...



   a) one, that the user has read-only access to and shows up in his
folders list, that is used only for system-related messages, like
over-quota notices - and maybe even user-specific log-type errors could
be delivered here?
   b) and one (hidden) that the user does *not* have access to, to
temporarily hold messages that come in that are unable to be delivered
due to an over-quota condition



Your taking control of my email and not delivering it?


That is not what I said - it is delivered - the system admin simply 
prevents the end user from seeing it unless/until they rectify their 
over-quota condition.



In my experience this would cause both a potential backlash and a
people resending mail.


I don't see how that would be a problem... the user will see *something* 
in their Inbox, and unless they are a *total* moron, they will actually 
*read* the message that is generated - especially since it will have a 
subject yelling at them in all caps that they are over quota.



Especially since people really only look at their INBOX for new mail
or particular folders they have scripted. Using a 'poll all fodlers
for new mail' I could see I had new mail in your 'a' folder. But that
would be the only way.


I agree, and actually, I thought of a better way after I sent that...

I'm guessing that dovecot could over-ride the Quota limit to inject 
small system generated messages like over-quota - so, forget about the 
folder 'a'...


How about every time a message comes in while the user is over-quota, 
dovecot injects another notification saying so directly in the users 
Inbox - ie, 'Message with Subject: blah has been received from 
blahblah, but you are #MB over quota - no new messages will be 
delivered to your Inbox until you delete some messages or move them to 
'Local Folders'.


Of course, this message should be fully customizable using variables...


This is how it actually works right now if configured, only the 'B'
folder is sender's /var/mail/spool


I'm not sure what you mean - most systems I have seen are configured to 
reject mail for users who are over quota. I know that postfix can be 
configured to soft-bounce, which is a part of what I'm talking about...


But I'd like a nice, clean, simple way for users to:

1. Know they are over-quota.

2. Never have mail rejected if they go over quota

3. Have a way of informing them when new messages have arrived but are 
being held pending rectification of their over-quota condition.


4. Provide a configurable way to send a notification to the sender that 
the email was accepted for delivery, but it being held pending 
rectification of an over quota condition.


This way, the user has only themselves to blame, and as long as this 
works reliably, I should never get a phone call about an over quota 
situation.


I'd prefer to handle this totally at the server level, and give a 
consistent experience regardless of the client used.



Off topic but you could also wrap your MTA (easily do this with
exim and I am sure others) to 'deny message  = Achtung! your so over
quota man\ncondition = ${run{gimmequota.pl}}\nhosts = local_domains
if you want that instant 'halt your over quota' experience.


See above - I'm not doing this to be mean - I'm just trying to figure 
out a viable way of managing quotas that will be user friendly for the 
users, so that they won;t have to call me.


--

Best regards,

Charles


Re: [Dovecot] Quota handling - opportunity for new Feature?

2007-05-22 Thread Gabriel Millerd

On 5/22/07, Charles Marcus [EMAIL PROTECTED] wrote:



 Your taking control of my email and not delivering it?

That is not what I said - it is delivered - the system admin simply
prevents the end user from seeing it unless/until they rectify their
over-quota condition.


  Unlikely the user will see the difference in deliver and received.

  I am envisioning a situation like this Sales Droid: sold send me
that quote, techdata rep: sending, hear back from you soon,
server: receipt received  receipt delivered, mail sent to 'B'
folder. At that moment I am getting called on where the mail is and I
get to watch an episode of Sales Droid: CSI.


 In my experience this would cause both a potential backlash and a
 people resending mail.

I don't see how that would be a problem... the user will see *something*
in their Inbox, and unless they are a *total* moron, they will actually
*read* the message that is generated - especially since it will have a
subject yelling at them in all caps that they are over quota.


  If SalesDroid is on the phone with someone and wants a document and
doesn't get the document, but the sender gets receipt for the document
temperatures rise, then the SalesDroid heads to gmail and emails
themselves a message 'test message to my crappy mail server' and he
gets it (because its small and fits under the radar temperatures rise
further and the request to 'send it again' or what not occurs and the
'B' folder starts getting packed.



I'm guessing that dovecot could over-ride the Quota limit to inject
small system generated messages like over-quota - so, forget about the
folder 'a'...


  Ummm, it can override the quota if its not a filesystem quota. If
its a filesystem quota touching the disk gets tricky, even differences
in types of buffered IO gets gross. But yes with a quota like
Maildir++ you need a LDA that will honor the quota accounting system
and a popmail and imap server that will as well. You could simple
alter the dovecot LDA script to drop a small textfile in
~/Maildir/new/ manually. Tweaking it to not be obnoxious which is why
I remove the previous alert and replace it with a new one.


How about every time a message comes in while the user is over-quota,


  I would assume people would go spastic about the INBOX spam, not to
mention quickly adding these messages to a filter even. You really
need to delete the previous messages I think unless this is a daily or
less infrequent thing I think.



I'm not sure what you mean - most systems I have seen are configured to
reject mail for users who are over quota. I know that postfix can be
configured to soft-bounce, which is a part of what I'm talking about...


  I see, I guess with a Hotmail or what not this might work. I would
rather 450 quota issues since they will get resolved soon. Just like
greylisting you can just have the sender's email message try again
later gracefully.


But I'd like a nice, clean, simple way for users to:


  With pop-mail this was easy, because you have bulletins. Lots of
issues with imap.

--
Gabriel Millerd


Re: [Dovecot] Quota handling - opportunity for new Feature?

2007-05-22 Thread Charles Marcus

Your taking control of my email and not delivering it?



That is not what I said - it is delivered - the system admin simply
prevents the end user from seeing it unless/until they rectify their
over-quota condition.



Unlikely the user will see the difference in deliver and received.


Sure they will - since if one is delivered but the user is over-quota, 
they *will* get a message/notification that the server received their 
message (even telling them the subject *and* *who* *it* *is* *from* - 
why on earth would they bother telling the sender they haven't received it?


And if you come back and say - 'Hey, users are stoopid' - well, then 
allow me to retort - if they are *that* stupid, then they should be 
fired - pure and simple.


The fact is, if this were implemented, they would be much *less* likely 
to bother you, because they would have a status message in their Inbox 
telling them everything - *including* *how* *to* *fix* *it* *with* 
*your* *own* *custom* *instructions* - whereas, currently, what 
notification they get depends on the client.



I am envisioning a situation like this Sales Droid: sold send me
that quote, techdata rep: sending, hear back from you soon,
server: receipt received  receipt delivered, mail sent to 'B'
folder. At that moment I am getting called on where the mail is and I
get to watch an episode of Sales Droid: CSI.


No, you wouldn't - because the Sales Droid would have a notification in 
their Inbox that the message had been received, *but* wouldn't be 
delivered to their Inbox until they resolved their over-quota situation.


If they call me (as the sys admin), and I ask them the standard 
questions - did you get a notice in your Inbox about receiving the 
message but being over quota? yes? Did you deal with the over quota 
problem? no? well, what the hell are you calling me for then - deal with 
the problem!


Now, obviously, this would all have to be configurable (I'm guessing 
this would all live in the Quota Plugin - or maybe it would be an 
alternate Quota plugin) - off by default, etc...



In my experience this would cause both a potential backlash and a
people resending mail.


Not at all - because the recipient *will* *know* they received the 
message, including the subject, the size, attachments, and who it is from.



I don't see how that would be a problem... the user will see *something*
in their Inbox, and unless they are a *total* moron, they will actually
*read* the message that is generated - especially since it will have a
subject yelling at them in all caps that they are over quota.



If SalesDroid is on the phone with someone and wants a document and
doesn't get the document, but the sender gets receipt for the document
temperatures rise,


How exactly is my proposed method for dealing with the over quota 
situation *worse* than what it is currently??



then the SalesDroid heads to gmail and emails themselves a message
'test message to my crappy mail server' and he gets it (because its
small and fits under the radar temperatures rise further and the
request to 'send it again' or what not occurs and the 'B' folder
starts getting packed.


Same question...

Again this can all be dealt with very simply, by the notification 
message. It can tell them precisely what wasn't delivered, *and* *why* - 
ie, because it is a large message and would put them over quota - 
complete with your custom instructions on how to fix the problem and get 
their message immediately.



I'm guessing that dovecot could over-ride the Quota limit to inject
small system generated messages like over-quota - so, forget about the
folder 'a'...



Ummm, it can override the quota if its not a filesystem quota.


Ok, so this would only work under certain conditions. Fine... lots of 
things work like that... you can only use maildir++ quotas with maildir 
- fine...



How about every time a message comes in while the user is over-quota,



I would assume people would go spastic about the INBOX spam,


Ridiculous... don't punish me for your poor training/support or poor 
hiring criteria.


If you really do have such morons (and/or poor training/support) that 
they cannot learn to trust that if they get a message in their Inbox 
saying they won't get any new mail delivered until they deal with their 
quota problem - and then try to filter this system notice, rather than 
deal with the over quota problem - well, then you have a much worse 
problems than stupid users - you have an 'incompetent admin' problem.



not to mention quickly adding these messages to a filter even.


Oh, please - that is ridiculous. If they are saavy enough to create a 
filter to filter them out, they are saavy enough to understand the 
message *and* *deal* *with* *the* *problem*.



You really need to delete the previous messages I think unless this
is a daily or less infrequent thing I think.


A very good idea, thanks - this message - or maybe a better word would 
be 'dovecot quota status message' - could