Results 1 to 6 of 6
Iam using postfix 2.3.3 with LDAP, courier-imap and squirrel mail
It is working fine. Now when i add users to LDAP, the maildirectories should be created auotmatically with username and ...
- 09-07-2011 #1Just Joined!
- Join Date
- Jun 2009
- Posts
- 22
Automatic creation of maildirs in postfix
Iam using postfix 2.3.3 with LDAP, courier-imap and squirrel mail
It is working fine. Now when i add users to LDAP, the maildirectories should be created auotmatically with username and maildirsize .(IN LDAP maildirpath=/var/postfix/maildirs/username).
But with qmail, it is automatically creating. How can do in postfix????
whether maildrop maildirmake or /etc/skel have to use achieve this.
??????????????
Any help Appreciated...................
- 09-13-2011 #2Just Joined!
- Join Date
- Sep 2011
- Posts
- 19
Postfix is known not to create directories for you, I always fix this by modifying /etc/skel as you suggest, or adding it to your create user script somewhere.
--Eric
- 09-14-2011 #3Just Joined!
- Join Date
- Jun 2009
- Posts
- 22
How to fix with /etc/skel
How to fix this problem with /etc/skel??? can u give me detailed steps???
Any create user script is available for that??????
Plz help me
- 09-14-2011 #4Just Joined!
- Join Date
- Sep 2011
- Posts
- 52
Just copy an existing empty(with no mail files in it) Maildir to /etc/skel.
From my experience I learned that the maildir is added automatically when you login via POP/IMAP or an email is sent to the newly created mail account. Doesn't it happen to you the same?
- 09-14-2011 #5Just Joined!
- Join Date
- Jun 2009
- Posts
- 22
maildrop - maildirmake
i have installed maildrop. in that using maildirmake only iam manually creating maildirs.
maildirmake /var/postfix/maildrs/sample
chown -R vmail:vmail /var/postfix/maildirs/sample
then cur,tmp,new folder is coming.........
when i login IMAP server , maildirsize is created automatically....
But i want to create maildir automatically..........
- 09-15-2011 #6Just Joined!
- Join Date
- Sep 2011
- Posts
- 19
I do not believe there is a way for Courier IMAP to create this automatically, but you could put this command in Cron and run every five minutes; then when you add users to the system their mail directory will be created within five minutes:
getent passwd | cut -f1 -d: | while read u; do
if ! [ -d "/var/postfix/maildirs/$u" ]; then
mkdir -p "/var/postfix/maildirs/$u/"{cur,tmp,new}
chown -R vmail:vmail "/var/spool/maildirs/$u"
fi
done
It is a bit of a hack, it would work!
-Eric


Reply With Quote