5 messages in net.sourceforge.lists.courier-maildropRE: [maildropl] How-to quotas with ma...
FromSent OnAttachments
AnaMay 12, 2004 2:13 am 
Michael McNeilMay 12, 2004 8:31 am.config
Andreas StollarMay 12, 2004 9:36 am 
Devin RubiaMay 12, 2004 9:36 am 
Tony EarnshawMay 13, 2004 4:40 pm 
Actions with this message:
Paste this link in email or IM:
Paste this link in email or IM:
Atom feed for this thread
Paste this URL into your reader:
Subject:RE: [maildropl] How-to quotas with maildrop-ldapActions...
From:Michael McNeil (mmcn@inphonic.com)
Date:May 12, 2004 8:31:54 am
List:net.sourceforge.lists.courier-maildrop
Attachments:
maildropldap.config - 6k

Ana,

I had the same issue a while back. Here's what I did to get maildrop/imap
quotas working for virtual users

1. Make sure each virtual user has the mailQuota attribute in the LDAP database 2. Set the uidNumber and gidNumber attribute to the same uid and gid of the user
who owns the mail store, I use vmail.

I'm attaching a copy of my maildropldap.config for your reference. If you read
the file carefully, you'll see EXACTLY what you need to do. There is an example
LDAP entry at the end of the maildropldap.config file. I hope this helps. If
not, let me know and I'll give you the step by step instructions.

Ciao,

Mike McNeil Sr. Network Engineer Inphonic, Inc. U.C. Division

-----Original Message----- From: cour@lists.sourceforge.net on behalf of Ana Sent: Wed 5/12/2004 2:17 AM To: cour@lists.sourceforge.net Cc: Subject: [maildropl] How-to quotas with maildrop-ldap

-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1

Hello! I need help to configure quotas with maildrop-ldap. I've read a lot of messages abouts this, but I'm not able to get this works. My setup: Postfix 2.1 Courier-imap 3.0 Maildrop 1.6.3 with suppor for LDAP OpenLDAP 2.1 I've virtual users and I've configured my maildropldap.conf to use quotas. Postfix: mailbox_command= maildrop Courier-Imap: LDAP_MAILDIRQUOTA quota Maildropldap.conf: quota_attr quota

All users authenticated OK, but quota doesn't work OK. Must I configure maildroprc? How? homeDirectory is in LDAP. Beside, If I want to send quotawarnmsg, I thint I have to use deliverquota: deliverquota -w 90 500S ./Maildir, but 500S is storaged in LDAP server and ./Maildir too. Must I use .mailfilter for each user? How can I get create Maildir the first time user receives an e-mail?

Thanks in advance.

- -- Un cordial saludo Ana

-----BEGIN PGP SIGNATURE----- Version: PGP 8.0.2

iQA/AwUBQKHrwQ8kP8jz9+HpEQJmEgCg/i39BaIKYz3izNQ3loZ8lwtOmKkAmwT7 3/dMzSCUvHtFMjELKFLVHvMp =g3sf -----END PGP SIGNATURE-----

------------------------------------------------------- This SF.Net email is sponsored by Sleepycat Software Learn developer strategies Cisco, Motorola, Ericsson & Lucent use to deliver higher performing products faster, at low TCO. http://www.sleepycat.com/telcomwpreg.php?From=osdnemail3 _______________________________________________ Courier-maildrop mailing list Cour@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/courier-maildrop

# Sample maildropldap.conf file, to enable virtual users via # LDAP in maildrop. # # In order for the LDAP extension to work properly a few # attributes must exist in the LDAP entries. # # You may redefine the actual names of these attributes, as they appear # in your LDAP object class further down in this config file. # # The attributes are: # # mail - The full email address of the user (ie us@yourdomain.com) # This is the primary attribute searched upon by maildrop. # # maildir - The location (full path including name) of the users # mail directory (Maildir) # # homedirectory - The location (full path including name) of the # users home directory. This may be the same as the # users maildir. # # uidnumber - The uid of the user that owns the mail files for # this user. This may be a specific uid per user, # or a single uid for every user (full 'virtual' user # configuration), or a combination. # # gidnumber - The gid of the user that owns the mail files for # this user. This may be a specific gid per user, # or a single gid for every user (full 'virtual' user # configuration), or a combination. # # quota - *OPTIONAL* The quota for this user. If blank, or # non-existent defaults to no quota. # # A sample LDAP entry is given at the end of this file. # # --- Actual configuration begins here -----------------------------

# hostname - host name of your ldap server hostname bilou.uc.inphonic.com

# basedn - base DN by which to search for LDAP entries basedn dc=U2,dc=com

# filter - optional, addition filter to add to # default 'mail=<email address>' # 'emailstatus' is an attribute which could be created in the # LDAP entry to set whether or not the user is allowed to # receive email on this box.. just an example # # this option can be left out and the default search would # just be 'mail=<email address>' #filter &(&(objectclass=vmailAccount)(emailstatus=active))

# binddn, bindpw - optional, binddn and password if your ldap server # requires you to authenticate before searching binddn cn=Admin,dc=U2,dc=com bindpw secret

# timeout - specifies maximum time ( in seconds ) to wait for a response # from the LDAP server timeout 5

# search_method - used to specify whether to search on the users id, or # email address, and may be either 'mail' or 'uid' # # if set to 'mail' (default) then to deliver mail to a user you must # specify the entire email address: # ie. maildrop -d joeu@domain.com # # if set to 'uid' then to deliver mail to a user you need only specify # the users id (username) # ie. maildrop -d joeuser # search_method uid

# default_uid - default uid (number only) to use incase uidnumber attribute not # found in users ldap entry default_uidnumber 1000

# default_gid - default gid (number only) to use incase gidnumber attribute not # found in users ldap entry default_gidnumber 1000

# LDAP Field definitions # # This section allows you to specify the actual attributes you # use in your LDAP object class # # The example attribute mapping shown below is also the default # mapping used by maildrop in the case that any are missing

# MAIL_ATTR - LDAP attribute which contains the users complete email address mail_attr mail

# UID_ATTR - LDAP attribute which contains the users name (w/o domain) uid_attr uid

# UIDNUMBER_ATTR - LDAP attribute which contains the system uid to deliver # mail as uidnumber_attr dummy

# GIDNUMBER_ATTR - LDAP attribute which contains the system gid to deliver # mail as gidnumber_attr dummy

# MAILDIR_ATTR - LDAP attribute which contains the path to the users # custom maildir maildir_attr mailMessageStore

# HOMEDIRECTORY_ATTR - LDAP attribute which contains the path to the users # home directory homedirectory_attr homeDirectory

# QUOTA_ATTR - LDAP attribute which contains the users quota quota_attr mailQuota

# --- Sample LDAP entry for a valid virtual user # --- Using attributes specified above # # mail=jo@yourdomain.com,dc=yourdomain,dc=com # emailstatus=active # objectclass=vmailAccount # maildir=/var/mail/virtual/mailboxes/joe # mail=jo@yourdomain.com # cn=Joe User # uid=joe # uidnumber=1900 # gidnumber=1900 # quota=2097152S,1000C # homedirectory=/var/mail/virtual/mailboxes/joe # userpassword={crypt}asViVeLinxDlI